DragonBattle API
Open
Nobody has claimed this yet.
status: accepted
version: 26.2
- Dominant language
- Java
- Stars
- 12.7k
- Forks
- 3.5k
- Avg merge
- 3d 13h
- Merged PRs (30d)
- 11
Description
Expected behavior
- Calling
DragonBattle#initiateRespawn()or the other one with Collection arg, should start the dragon respawn sequence, advancinggetRespawnPhase()as the vanilla animation runs - Calling
resetCrystals()should reset the crystals on the obsidian pillars
Observed/Actual behavior
- Calling
initiateRespawn(List.of())reports phaseSTARTfor a moment, then immediately goes back toNONEon the next check. (it only tries to respawn torches for some reason) - Calling
initiateRespawn()(no-arg) never shows anything other thanNONE. resetCrystals()does nothing at all- No exceptions or warnings are printed to console in any case.
Steps/models to reproduce
- Kill the dragon
- Try calling any of these methods
- Observe
Plugin and Datapack List
> plugins
[12:54:33 INFO]: ℹ Server Plugins (1):
[12:54:33 INFO]: Bukkit Plugins:
[12:54:33 INFO]: - TestPlugin
> datapack list
[12:54:36 INFO]: There are 3 data pack(s) enabled: [vanilla (built-in)], [file/bukkit (world)], [paper (built-in)]
[12:54:36 INFO]: There are no more data packs available
>
Paper version
> version
[12:55:38 INFO]: This server is running Paper version 26.2-112-main@c9e894d (2026-08-11T05:18:39Z) (Implementing API version 26.2.build.112-stable)
You are running the latest version
Previous version: 26.2-87-a95ae8d (MC: 26.2)
Other
My minimal test command
public class DragonBattleCommand {
public static LiteralCommandNode<CommandSourceStack> command() {
return Commands.literal("dragonbattle")
.then(Commands.literal("start_print")
.executes(context -> {
Player player = getPlayer(context.getSource());
DragonBattle battle = getBattle(player);
Bukkit.getServer().getScheduler().runTaskTimer(TestPlugin.instance, () -> {
sendPhaseInfo(player, battle);
}, 0, 20);
return Command.SINGLE_SUCCESS;
}))
.then(Commands.literal("initiate")
.executes(context -> {
Player player = getPlayer(context.getSource());
DragonBattle battle = getBattle(player);
sendPhaseInfo(player, battle);
battle.initiateRespawn();
player.sendMessage("Initiated respawn");
sendPhaseInfo(player, battle);
return Command.SINGLE_SUCCESS;
}))
.then(Commands.literal("initiate_empty")
.executes(context -> {
Player player = getPlayer(context.getSource());
DragonBattle battle = getBattle(player);
sendPhaseInfo(player, battle);
battle.initiateRespawn(List.of());
sendPhaseInfo(player, battle);
return Command.SINGLE_SUCCESS;
}))
.then(Commands.literal("reset_crystals")
.executes(context -> {
Player player = getPlayer(context.getSource());
DragonBattle battle = getBattle(player);
sendPhaseInfo(player, battle);
battle.resetCrystals();
sendPhaseInfo(player, battle);
return Command.SINGLE_SUCCESS;
}))
.build();
}
private static void sendPhaseInfo(Player player, DragonBattle battle) {
player.sendMessage("Respawn phase now: " + battle.getRespawnPhase().name());
}
private static Player getPlayer(CommandSourceStack source) {
return (Player) source.getExecutor();
}
private static DragonBattle getBattle(Player player) {
return player.getWorld().getEnderDragonBattle();
}
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the DragonBattle implementation behind initiateRespawn(), its Collection overload, resetCrystals(), and getRespawnPhase(). Use the supplied Java command and the listed Paper version to reproduce each behavior. Done means both respawn entry points advance through the vanilla sequence and resetCrystals() resets the obsidian-pillar crystals without warnings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, game-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100