fixed bug in player_offered_item regarding group checks
This commit is contained in:
parent
0b000a3b94
commit
a60afada41
@ -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" ]
|
local data = yl_speak_up.speak_to[pname][ "tmp_action" ]
|
||||||
if(not(data) or (data.what ~= 4 and data.what ~= 5)) then
|
if(not(data) or (data.what ~= 4 and data.what ~= 5)) then
|
||||||
-- we are editing an action
|
-- we are editing an action
|
||||||
if(data) then
|
if(data and data.what ~= 10) then
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
-- it might be a precondition
|
-- it might be a precondition
|
||||||
data = yl_speak_up.speak_to[pname][ "tmp_prereq" ]
|
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
|
return
|
||||||
end
|
end
|
||||||
target_fs = "edit_preconditions"
|
target_fs = "edit_preconditions"
|
||||||
|
@ -7,6 +7,7 @@ yl_speak_up.input_add_trade_simple = function(player, formname, fields, input_to
|
|||||||
return 0
|
return 0
|
||||||
end
|
end
|
||||||
local pname = player:get_player_name()
|
local pname = player:get_player_name()
|
||||||
|
local n_id = yl_speak_up.speak_to[pname].n_id
|
||||||
|
|
||||||
input_to = "add_trade_simple"
|
input_to = "add_trade_simple"
|
||||||
-- are we editing an action of the type trade?
|
-- are we editing an action of the type trade?
|
||||||
|
Loading…
Reference in New Issue
Block a user