mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2025-01-31 04:12:37 +01:00
Stankman Easter Egg
This commit is contained in:
parent
83d1436983
commit
e11def5965
@ -57,6 +57,8 @@ public abstract class RoomUnit extends RoomEntity {
|
|||||||
private boolean isSwimming = false;
|
private boolean isSwimming = false;
|
||||||
@Setter
|
@Setter
|
||||||
private boolean cmdFastWalkEnabled;
|
private boolean cmdFastWalkEnabled;
|
||||||
|
@Setter
|
||||||
|
private boolean temporalFastWalkEnabled;
|
||||||
private final ConcurrentHashMap<RoomUnitStatus, String> statuses;
|
private final ConcurrentHashMap<RoomUnitStatus, String> statuses;
|
||||||
@Setter
|
@Setter
|
||||||
private boolean statusUpdateNeeded;
|
private boolean statusUpdateNeeded;
|
||||||
@ -118,6 +120,8 @@ public abstract class RoomUnit extends RoomEntity {
|
|||||||
public void cycle() {
|
public void cycle() {
|
||||||
if(this.isWalking()) {
|
if(this.isWalking()) {
|
||||||
this.processWalking();
|
this.processWalking();
|
||||||
|
} else {
|
||||||
|
this.stopWalking();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -144,12 +148,18 @@ public abstract class RoomUnit extends RoomEntity {
|
|||||||
|
|
||||||
public void stopWalking() {
|
public void stopWalking() {
|
||||||
synchronized (this.statuses) {
|
synchronized (this.statuses) {
|
||||||
this.path.clear();
|
if(this.path != null) {
|
||||||
|
this.path.clear();
|
||||||
|
}
|
||||||
|
|
||||||
this.nextPosition = null;
|
this.nextPosition = null;
|
||||||
this.targetPosition = null;
|
this.targetPosition = null;
|
||||||
|
|
||||||
this.removeStatus(RoomUnitStatus.MOVE);
|
this.removeStatus(RoomUnitStatus.MOVE);
|
||||||
this.handleSitStatus();
|
this.handleSitStatus();
|
||||||
this.handleLayStatus();
|
this.handleLayStatus();
|
||||||
|
|
||||||
|
this.temporalFastWalkEnabled = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -489,7 +499,7 @@ public abstract class RoomUnit extends RoomEntity {
|
|||||||
if(!this.path.isEmpty()) {
|
if(!this.path.isEmpty()) {
|
||||||
RoomTile next = this.path.poll();
|
RoomTile next = this.path.poll();
|
||||||
|
|
||||||
if(this.path.size() > 1 && this.cmdFastWalkEnabled) {
|
if(this.path.size() > 1 && (this.cmdFastWalkEnabled || this.temporalFastWalkEnabled)) {
|
||||||
next = this.path.poll();
|
next = this.path.poll();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -39,7 +39,6 @@ public class MoveAvatarEvent extends MessageHandler {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (roomHabbo.getCurrentPosition().equals(x,y) && roomHabbo.isAtGoal()) {
|
if (roomHabbo.getCurrentPosition().equals(x,y) && roomHabbo.isAtGoal()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -63,6 +62,9 @@ public class MoveAvatarEvent extends MessageHandler {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//STANKMAN EASTER EGG
|
||||||
|
roomHabbo.setTemporalFastWalkEnabled(roomHabbo.getTargetPosition() != null && roomHabbo.getTargetPosition().equals(tile));
|
||||||
|
|
||||||
roomHabbo.walkTo(tile);
|
roomHabbo.walkTo(tile);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user