From b97aeca76637d33e5e2aa096913a550b4f30027a Mon Sep 17 00:00:00 2001 From: brenoepic <59066707+brenoepics@users.noreply.github.com> Date: Sat, 3 Dec 2022 16:02:35 -0300 Subject: [PATCH] add checks --- .../habbohotel/games/battlebanzai/BattleBanzaiGameTeam.java | 2 +- .../com/eu/habbo/habbohotel/games/freeze/FreezeGameTeam.java | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/eu/habbo/habbohotel/games/battlebanzai/BattleBanzaiGameTeam.java b/src/main/java/com/eu/habbo/habbohotel/games/battlebanzai/BattleBanzaiGameTeam.java index 4454cc79..2156e471 100644 --- a/src/main/java/com/eu/habbo/habbohotel/games/battlebanzai/BattleBanzaiGameTeam.java +++ b/src/main/java/com/eu/habbo/habbohotel/games/battlebanzai/BattleBanzaiGameTeam.java @@ -37,7 +37,7 @@ public class BattleBanzaiGameTeam extends GameTeam { Game game = habbo.getHabboInfo().getCurrentRoom().getGame(FreezeGame.class); RoomUnit roomUnit = habbo.getRoomUnit(); Room room = roomUnit.getRoom(); - + if(room == null) return; HabboItem topItem = room.getTopItemAt(roomUnit.getCurrentLocation().x, roomUnit.getCurrentLocation().y); int nextEffectM = 0; int nextEffectF = 0; diff --git a/src/main/java/com/eu/habbo/habbohotel/games/freeze/FreezeGameTeam.java b/src/main/java/com/eu/habbo/habbohotel/games/freeze/FreezeGameTeam.java index b00b57f2..dea71694 100644 --- a/src/main/java/com/eu/habbo/habbohotel/games/freeze/FreezeGameTeam.java +++ b/src/main/java/com/eu/habbo/habbohotel/games/freeze/FreezeGameTeam.java @@ -27,6 +27,7 @@ public class FreezeGameTeam extends GameTeam { Game game = habbo.getHabboInfo().getCurrentRoom().getGame(FreezeGame.class); RoomUnit roomUnit = habbo.getRoomUnit(); Room room = roomUnit.getRoom(); + if(room == null) return; HabboItem topItem = room.getTopItemAt(roomUnit.getCurrentLocation().x, roomUnit.getCurrentLocation().y); int nextEffectM = 0;