mirror of
https://github.com/SunNetservers/MiniGames.git
synced 2025-07-24 00:35:28 +02:00
Adds an option to enforce ordered checkpoint triggering
This commit is contained in:
@@ -13,6 +13,7 @@ public class ParkourConfiguration extends MiniGameConfiguration {
|
||||
|
||||
private final static String rootNode = "parkour.";
|
||||
|
||||
private boolean enforceCheckpointOrder;
|
||||
private boolean mustDoGroupedInSequence;
|
||||
private boolean ignoreRecordsUntilGroupBeatenOnce;
|
||||
private boolean makePlayersInvisible;
|
||||
@@ -27,6 +28,15 @@ public class ParkourConfiguration extends MiniGameConfiguration {
|
||||
super(configuration);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets whether all checkpoints must be triggered in the order they are set when configuring the parkour arena
|
||||
*
|
||||
* @return <p>Whether checkpoints must be triggered in order</p>
|
||||
*/
|
||||
public boolean enforceCheckpointOrder() {
|
||||
return this.enforceCheckpointOrder;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets whether grouped arenas must be done in the set sequence
|
||||
*
|
||||
@@ -65,6 +75,7 @@ public class ParkourConfiguration extends MiniGameConfiguration {
|
||||
|
||||
@Override
|
||||
protected void load() {
|
||||
this.enforceCheckpointOrder = configuration.getBoolean(rootNode + "enforceCheckpointOrder", false);
|
||||
this.mustDoGroupedInSequence = configuration.getBoolean(rootNode + "mustDoGroupedInSequence", true);
|
||||
this.ignoreRecordsUntilGroupBeatenOnce = configuration.getBoolean(rootNode + "ignoreRecordsUntilGroupBeatenOnce", false);
|
||||
this.makePlayersInvisible = configuration.getBoolean(rootNode + "makePlayersInvisible", false);
|
||||
|
Reference in New Issue
Block a user