mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2025-01-31 12:22:36 +01:00
Fix room moderation achievements
This commit is contained in:
parent
7ec6c20c5d
commit
e06814b259
@ -149,7 +149,7 @@ public final class Emulator {
|
|||||||
|
|
||||||
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
|
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
|
||||||
|
|
||||||
while (!isShuttingDown && isReady) {
|
while (!isShuttingDown && isReady && reader.ready()) {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
String line = reader.readLine();
|
String line = reader.readLine();
|
||||||
|
@ -53,7 +53,6 @@ public class TestCommand extends Command {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean handle(GameClient gameClient, String[] params) throws Exception {
|
public boolean handle(GameClient gameClient, String[] params) throws Exception {
|
||||||
if (true) return true;
|
|
||||||
if (params[1].equalsIgnoreCase("ut")) {
|
if (params[1].equalsIgnoreCase("ut")) {
|
||||||
RoomTile tile = gameClient.getHabbo().getRoomUnit().getCurrentLocation();
|
RoomTile tile = gameClient.getHabbo().getRoomUnit().getCurrentLocation();
|
||||||
gameClient.getHabbo().getHabboInfo().getCurrentRoom().updateTile(tile);
|
gameClient.getHabbo().getHabboInfo().getCurrentRoom().updateTile(tile);
|
||||||
|
@ -152,7 +152,7 @@ public class InteractionWater extends InteractionDefault {
|
|||||||
if(pet == null)
|
if(pet == null)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (!pet.getRoomUnit().hasStatus(RoomUnitStatus.SWIM)) {
|
if (!pet.getRoomUnit().hasStatus(RoomUnitStatus.SWIM) && pet.getPetData().canSwim) {
|
||||||
pet.getRoomUnit().setStatus(RoomUnitStatus.SWIM, "");
|
pet.getRoomUnit().setStatus(RoomUnitStatus.SWIM, "");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -213,4 +213,13 @@ public class InteractionWater extends InteractionDefault {
|
|||||||
|
|
||||||
return super.canStackAt(room, itemsAtLocation);
|
return super.canStackAt(room, itemsAtLocation);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean canWalkOn(RoomUnit roomUnit, Room room, Object[] objects) {
|
||||||
|
if (!super.canWalkOn(roomUnit, room, objects)) return false;
|
||||||
|
|
||||||
|
Pet pet = room.getPet(roomUnit);
|
||||||
|
|
||||||
|
return pet == null || pet.getPetData().canSwim;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -558,7 +558,9 @@ public class Room implements Comparable<Room>, ISerialize, Runnable {
|
|||||||
RoomTileState result = RoomTileState.OPEN;
|
RoomTileState result = RoomTileState.OPEN;
|
||||||
HabboItem lowestItem = null;
|
HabboItem lowestItem = null;
|
||||||
HabboItem lowestChair = this.getLowestChair(tile);
|
HabboItem lowestChair = this.getLowestChair(tile);
|
||||||
for (HabboItem item : this.getItemsAt(tile)) {
|
THashSet<HabboItem> items = this.getItemsAt(tile);
|
||||||
|
if (items == null) return RoomTileState.INVALID;
|
||||||
|
for (HabboItem item : items) {
|
||||||
if (exclude != null && item == exclude) continue;
|
if (exclude != null && item == exclude) continue;
|
||||||
|
|
||||||
if (lowestChair != null && item.getZ() > lowestChair.getZ() + 1.5) {
|
if (lowestChair != null && item.getZ() > lowestChair.getZ() + 1.5) {
|
||||||
|
@ -15,12 +15,5 @@ public class RequestRoomSettingsEvent extends MessageHandler {
|
|||||||
|
|
||||||
if (room != null)
|
if (room != null)
|
||||||
this.client.sendResponse(new RoomSettingsComposer(room));
|
this.client.sendResponse(new RoomSettingsComposer(room));
|
||||||
|
|
||||||
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModChatFloodFilterSeen"));
|
|
||||||
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModChatHearRangeSeen"));
|
|
||||||
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModChatScrollSpeedSeen"));
|
|
||||||
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModDoorModeSeen"));
|
|
||||||
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModWalkthroughSeen"));
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -31,6 +31,21 @@ public class UserActivityEvent extends MessageHandler {
|
|||||||
case "forum.can.moderate.seen":
|
case "forum.can.moderate.seen":
|
||||||
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModForumCanModerateSeen"));
|
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModForumCanModerateSeen"));
|
||||||
break;
|
break;
|
||||||
|
case "room.settings.doormode.seen":
|
||||||
|
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModDoorModeSeen"));
|
||||||
|
break;
|
||||||
|
case "room.settings.walkthrough.seen":
|
||||||
|
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModWalkthroughSeen"));
|
||||||
|
break;
|
||||||
|
case "room.settings.chat.scrollspeed.seen":
|
||||||
|
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModChatScrollSpeedSeen"));
|
||||||
|
break;
|
||||||
|
case "room.settings.chat.hearrange.seen":
|
||||||
|
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModChatHearRangeSeen"));
|
||||||
|
break;
|
||||||
|
case "room.settings.chat.floodfilter.seen":
|
||||||
|
AchievementManager.progressAchievement(this.client.getHabbo(), Emulator.getGameEnvironment().getAchievementManager().getAchievement("SelfModChatFloodFilterSeen"));
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user