Fix diplomacy from the perspective of

master
rubenwardy 2016-03-31 16:41:26 +01:00
parent 0db05b54ef
commit 904015f72c
1 changed files with 2 additions and 2 deletions

View File

@ -293,8 +293,8 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
if formname == "ctf:diplo" then
for key, field in pairs(fields) do
local tname2 = string.match(key, "team_(.+)")
if tname2 then
ctf.gui.show(name, "diplo")
if tname2 and ctf.team(tname2) then
ctf.gui.show(name, "diplo", tname2)
return true
end