mirror of
https://github.com/2006-Scape/apollo.git
synced 2026-07-06 16:51:37 +00:00
Update walking queue on run toggle.
This commit is contained in:
@@ -89,8 +89,6 @@ public final class Player extends Character {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The player's appearance.
|
* The player's appearance.
|
||||||
@@ -157,6 +155,11 @@ public final class Player extends Character {
|
|||||||
*/
|
*/
|
||||||
private boolean regionChanged = false;
|
private boolean regionChanged = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A flag indicating if this player is running.
|
||||||
|
*/
|
||||||
|
private boolean running = false;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The {@link GameSession} currently attached to this {@link Player}.
|
* The {@link GameSession} currently attached to this {@link Player}.
|
||||||
*/
|
*/
|
||||||
@@ -625,4 +628,23 @@ public final class Player extends Character {
|
|||||||
+ privilegeLevel + "]";
|
+ privilegeLevel + "]";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets whether the player is running or not.
|
||||||
|
*
|
||||||
|
* @return {@code true} if the player is running, otherwise {@code false}.
|
||||||
|
*/
|
||||||
|
public boolean isRunning() {
|
||||||
|
return running;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets whether the running toggle is enabled.
|
||||||
|
*
|
||||||
|
* @param running The toggle.
|
||||||
|
*/
|
||||||
|
public void setRunning(boolean running) {
|
||||||
|
this.running = running;
|
||||||
|
getWalkingQueue().setRunningQueue(running);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user