mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2025-12-27 03:25:23 +09:00
Fix no player character during bonus reset
This commit is contained in:
@@ -401,6 +401,9 @@ end
|
||||
--- @param player LuaPlayer
|
||||
function Elements.container.clear_player_bonus(player)
|
||||
Elements.container.data[player] = {}
|
||||
if not player.character then
|
||||
return
|
||||
end
|
||||
for _, bonus_data in pairs(config.player_bonus) do
|
||||
if not bonus_data.is_special then
|
||||
player[bonus_data.name] = 0
|
||||
|
||||
Reference in New Issue
Block a user