Message on friendly fire
This commit is contained in:
parent
665030b5d5
commit
e078025fa5
@ -426,8 +426,10 @@ minetest.register_on_punchplayer(function(player, hitter)
|
||||
local to = ctf.player(player:get_player_name())
|
||||
local from = ctf.player(hitter:get_player_name())
|
||||
|
||||
if not ctf.setting("friendly_fire") and to.team == from.team and
|
||||
to.team ~= "" and to.team ~= nil then
|
||||
if to.team == from.team and to.team ~= "" and to.team ~= nil then
|
||||
minetest.chat_send_player(from:get_player_name(), to:get_player_name() .. " is on your team!")
|
||||
if not ctf.setting("friendly_fire") then
|
||||
return true
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
Loading…
x
Reference in New Issue
Block a user