Class BreakBlockChallenge
java.lang.Object
com.storytimeproductions.models.stgames.challenges.BreakBlockChallenge
- All Implemented Interfaces:
StoryBlitzChallenge
Represents a challenge where players must break a block. This class implements the
StoryBlitzChallenge interface.
-
Constructor Summary
ConstructorsConstructorDescriptionBreakBlockChallenge(List<Cuboid> spawnRegions) Constructs a new BreakBlockChallenge with a random block type and count. -
Method Summary
Modifier and TypeMethodDescriptionvoidCleans up resources when the challenge ends.Returns the description of the challenge.booleanisCompleted(org.bukkit.entity.Player player) Checks if the player has completed the challenge.voidStarts the challenge for the given players.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface StoryBlitzChallenge
getDescriptionWithGoobModifier and TypeMethodDescriptiondefault StringgetDescriptionWithGoob(String normalDescription) Returns a description with a chance to include "goob" for fun.
-
Constructor Details
-
BreakBlockChallenge
-
-
Method Details
-
getDescription
Returns the description of the challenge.- Specified by:
getDescriptionin interfaceStoryBlitzChallenge- Returns:
- The description of the challenge.
-
start
Starts the challenge for the given players.- Specified by:
startin interfaceStoryBlitzChallenge- Parameters:
players- The players in the game.
-
isCompleted
public boolean isCompleted(org.bukkit.entity.Player player) Checks if the player has completed the challenge.- Specified by:
isCompletedin interfaceStoryBlitzChallenge- Parameters:
player- The player to check.- Returns:
- true if the player has completed the challenge, false otherwise.
-
cleanup
Cleans up resources when the challenge ends.- Specified by:
cleanupin interfaceStoryBlitzChallenge- Parameters:
players- The players in the game.
-