From b371f158013f4c4c69158cd6b45bf6efbb83ecea Mon Sep 17 00:00:00 2001 From: Sokomine Date: Sun, 8 Jun 2025 16:33:44 +0200 Subject: [PATCH] supported "at least" for accepting items --- exec_eval_preconditions.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/exec_eval_preconditions.lua b/exec_eval_preconditions.lua index 385dd14..25ef3fb 100644 --- a/exec_eval_preconditions.lua +++ b/exec_eval_preconditions.lua @@ -382,8 +382,11 @@ yl_speak_up.eval_precondition = function(player, n_id, p, other_options_true_or_ if(p.p_match_stack_size and p.p_match_stack_size ~= "") then local c_got = stack_got:get_count() local c_wanted = stack_wanted:get_count() + if( p.p_match_stack_size == "exactly" and c_got ~= c_wanted) then return false -- not exactly the same amount as the wanted one + elseif(p.p_match_stack_size == "at_least" and c_got < c_wanted) then + return false -- didn't get at least the wanted amount elseif(p.p_match_stack_size == "less" and c_got >= c_wanted) then return false -- didn't get less than the given number elseif(p.p_match_stack_size == "more" and c_got <= c_wanted) then