forked from mtcontrib/minetest_mana
Fix mana resetting for re-joining players
This commit is contained in:
parent
ff247cc261
commit
f6157dbc64
6
init.lua
6
init.lua
|
@ -204,8 +204,10 @@ end)
|
|||
|
||||
minetest.register_on_leaveplayer(function(player)
|
||||
local playername = player:get_player_name()
|
||||
mana.hud_remove(playername)
|
||||
mana.playerlist[playername] = nil
|
||||
if not minetest.get_modpath("hudbars") ~= nil then
|
||||
mana.hud_remove(playername)
|
||||
end
|
||||
mana.save_to_file()
|
||||
end)
|
||||
|
||||
minetest.register_on_shutdown(function()
|
||||
|
|
Loading…
Reference in New Issue
Block a user