The GameStages API expands CraftTweaker's IPlayer functionality to allow you to check and modify a player's stages.

Calling the methods

Link to calling-the-methods

As this is a ZenExpansion, you can simply call the methods on any IPlayer object, or any of it's subtypes.

Check for gamestages

Link to check-for-gamestages

The methods return booleans.

// Checks if the player has the passed stage.
//player.hasGameStage(String stage);

// Checks if the player has any of the passed stages. They only need one.
//player.hasAnyGameStages(String... stages);
player.hasAnyGameStages("one", "two");

// Checks if the player has all of the passed stages.
//player.hasAllGameStages (String... stages);
player.hasAllGameStages ("one", "two");

Add or remove a gamestage

Link to add-or-remove-a-gamestage

The methods return void (nothing).

// Unlocks a stage for a player.
//addGameStage(String stage);
addGameStage(String stage);

// Locks a stage for a player.
//removeGameStage(String stage);
removeGameStage(String stage);