mirror of
https://github.com/SunNetservers/MiniGames.git
synced 2025-09-17 11:27:55 +02:00
Makes looking around a dropper arena possible
This commit is contained in:
@@ -20,6 +20,7 @@ public class DropperArenaSession extends AbstractArenaSession {
|
||||
private final @NotNull DropperArena arena;
|
||||
private final @NotNull Player player;
|
||||
private final @NotNull DropperArenaGameMode gameMode;
|
||||
private boolean startedMoving = false;
|
||||
|
||||
/**
|
||||
* Instantiates a new dropper arena session
|
||||
@@ -39,6 +40,22 @@ public class DropperArenaSession extends AbstractArenaSession {
|
||||
this.entryState.setArenaState();
|
||||
}
|
||||
|
||||
/**
|
||||
* Marks that this arena's player has started moving
|
||||
*/
|
||||
public void setStartedMoving() {
|
||||
this.startedMoving = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets whether the player of this session has started moving in the arena
|
||||
*
|
||||
* @return <p>True if the player has started moving</p>
|
||||
*/
|
||||
public boolean getStartedMoving() {
|
||||
return this.startedMoving;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the player playing in this session
|
||||
*
|
||||
@@ -103,6 +120,12 @@ public class DropperArenaSession extends AbstractArenaSession {
|
||||
return new DropperGUI(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void reset() {
|
||||
this.startedMoving = false;
|
||||
super.reset();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void removeSession() {
|
||||
// Remove this session for game sessions to stop listeners from fiddling more with the player
|
||||
|
Reference in New Issue
Block a user