Fixed timers on the server-side.

This commit is contained in:
luisc committed 2021-10-22 02:22:45 -05:00
1 parent d1c4adf371
commit a29058d696
3 files changed
+5 -29

No files matched your search

@@ -63,11 +63,12 @@ public class ScriptPlayerEventHandler {
if(event.side == Side.SERVER && event.phase == TickEvent.Phase.START) {
EntityPlayer player = event.player;
PlayerData data = PlayerData.get(player);
//if(player.ticksExisted % 10 == 0) {
EventHooks.onPlayerTick(data.scriptData);
//}
data.timers.update();
if(PlayerDataController.instance != null) {
PlayerDataController.instance.getPlayerData(player).scriptData = data.scriptData;
PlayerDataController.instance.getPlayerData(player).timers.update();
}
}
}