mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2024-11-30 01:50:50 +01:00
Fix teleports on floorplaneditor
This commit is contained in:
parent
9c4b1df499
commit
bad061bfd1
@ -4480,6 +4480,10 @@ public class Room implements Comparable<Room>, ISerialize, Runnable {
|
||||
return FurnitureMovementError.MAX_ITEMS;
|
||||
}
|
||||
|
||||
if (tile == null || tile.state == RoomTileState.INVALID) {
|
||||
return FurnitureMovementError.INVALID_MOVE;
|
||||
}
|
||||
|
||||
rotation %= 8;
|
||||
if (this.hasRights(habbo) || this.getGuildRightLevel(habbo).isEqualOrGreaterThan(RoomRightLevels.GUILD_RIGHTS) || habbo.hasPermission(Permission.ACC_MOVEROTATE)) {
|
||||
return FurnitureMovementError.NONE;
|
||||
|
@ -51,6 +51,10 @@ class TeleportActionThree implements Runnable {
|
||||
|
||||
RoomTile teleportLocation = targetRoom.getLayout().getTile(targetTeleport.getX(), targetTeleport.getY());
|
||||
|
||||
if (teleportLocation == null) {
|
||||
Emulator.getThreading().run(new TeleportActionFive(this.currentTeleport, this.room, this.client), 0);
|
||||
return;
|
||||
}
|
||||
this.client.getHabbo().getRoomUnit().setLocation(teleportLocation);
|
||||
this.client.getHabbo().getRoomUnit().getPath().clear();
|
||||
this.client.getHabbo().getRoomUnit().removeStatus(RoomUnitStatus.MOVE);
|
||||
|
Loading…
Reference in New Issue
Block a user