Fixed some bugs

This commit is contained in:
Cooldude2606
2020-05-29 22:57:06 +01:00
parent 0836375e02
commit 4286e25803
6 changed files with 23 additions and 31 deletions

View File

@@ -23,8 +23,8 @@ local function apply_bonus(player, amount)
end
--- When store is updated apply new bonus to the player
PlayerBonus.on_update(function(player_name, player_bonus)
apply_bonus(game.player[player_name], player_bonus or 0)
PlayerBonus:on_update(function(player_name, player_bonus)
apply_bonus(game.players[player_name], player_bonus or 0)
end)
--- Changes the amount of bonus you receive