Creating Your Own Quest Types
public class BlockBreakQuest extends ExternalActionContainer {
public BlockBreakQuest(JavaPlugin plugin) {
super(plugin, "your_plugin_name");
}
@EventHandler(ignoreCancelled = true)
public void onBlockBreak(BlockBreakEvent event) {
Player player = event.getPlayer();
Block block = event.getBlock();
super.executionBuilder("quest_name") // Create execution
.player(player) // Set player
.root(block) // Set root
.progressSingle() // Add 1 progress
.buildAndExecute(); // Execute
}
}
Useful ActionExecutionBuilder methods
ActionExecutionBuilder methodsLast updated