fixed bug in player_offered_item regarding group checks

This commit is contained in:
Sokomine 2025-06-07 21:55:30 +02:00
parent 0b000a3b94
commit a60afada41
2 changed files with 3 additions and 2 deletions

View File

@ -21,12 +21,12 @@ yl_speak_up.action_inv_changed = function(inv, listname, index, stack, player, h
local data = yl_speak_up.speak_to[pname][ "tmp_action" ]
if(not(data) or (data.what ~= 4 and data.what ~= 5)) then
-- we are editing an action
if(data) then
if(data and data.what ~= 10) then
return
end
-- it might be a precondition
data = yl_speak_up.speak_to[pname][ "tmp_prereq" ]
if(not(data) or (data.what ~= 8)) then
if(not(data) or (data.what ~= 10)) then
return
end
target_fs = "edit_preconditions"

View File

@ -7,6 +7,7 @@ yl_speak_up.input_add_trade_simple = function(player, formname, fields, input_to
return 0
end
local pname = player:get_player_name()
local n_id = yl_speak_up.speak_to[pname].n_id
input_to = "add_trade_simple"
-- are we editing an action of the type trade?