The SerpentKing
A 300-block-long sculk-patterned serpent that cannot be stopped by walls, wards, or warning. Summoned deliberately — never spawns on its own — and hunts players and other snakes with no user interface to announce its arrival.
About
The Serpent King is a standalone boss fight in its own plugin, SerpentKing. It's designed as a bigger, faster, flying cousin of the Ancient Serpent found in the Snake plugin's Deep Dark — same sculk-and-deepslate palette, same venom profile, same brutal aggression, but scaled up to a 300-block flying apex that ignores terrain entirely.
It lives in its own Java package (com.example.serpentking) and requires no dependency on the Snake plugin to compile or run. However, if the Snake plugin is installed alongside it, the Serpent King will actively hunt every snake in its 300-block radius — including the Ancient Serpent itself.
Summoning & Spawning
The Serpent King never appears on its own. There is no biome, no dimension, no structure, no moonphase, and no block that triggers it. It exists only when an admin — or a player with the serpentking.admin permission — runs the /spawnboss command.
When /spawnboss is run by a player, the boss is spawned 20 blocks directly above them in that player's world. It begins descending toward the nearest valid target within the same tick. No inventory clearing, no gear handout, no ceremony — the boss arrives exactly like any other summoned mob.
- TriggerManual only —
/spawnbosscommand, players with theserpentking.adminpermission. - Location20 blocks above the running player's current location, in the same world.
- One per worldThe plugin tracks bosses in a per-world map keyed by World UUID — Multiverse-friendly. Running
/spawnbosswhile one is already active in your current world replies "already active in this world" and does nothing. You can still summon one in a different world simultaneously. - No gear givenThe player's inventory is untouched. Bring your own equipment — the boss spawns exactly like using
/summonon a vanilla mob. - Console safetyConsole cannot summon — only players. The command requires a player location to spawn above.
- On spawnA single
ENTITY_ENDER_DRAGON_GROWLsound plays at the spawn location, audible to anyone nearby. That's the only cue.
Persistence & Worlds
The Serpent King uses the same persistence model as the Snake plugin's named snakes. Once summoned, it is permanent — it survives chunk unloads, server restarts, plugin reloads, and player relogs. The only ways to remove it are to kill it or run /killboss.
On plugin enable the server does a 2-second-delayed scan of every loaded chunk in every world, finds any Husk tagged serpent_king, and wraps it in a fresh SerpentKingEntity. Phase is re-derived from HP — a boss you left at 40% HP last session comes back already in its corrupted phase-2 palette.
- Base entity
setPersistent(true)+setRemoveWhenFarAway(false)on the invisible husk. Saved to the chunk's entity data file like any other mob. - Scoreboard tag
serpent_kingon the base husk — the identifier the reconstruction scan looks for. - Startup scanRuns 40 ticks (2 seconds) after plugin enable to let Paper finish loading spawn-chunk entities. Clears any stale display entities first, then reconstructs every boss from its persisted husk. Logs a summary to console.
- Chunk-load eventsIf a boss's chunk unloaded at restart time (e.g. outside the spawn-chunk radius), a
ChunkLoadEventhandler catches it when a player walks close enough — reconstruction happens 2 ticks after the chunk loads. - Display entitiesDisplays are marked
setPersistent(false)so they don't save — they're recreated whenever the boss reconstructs. Each carries aserpent_king_displaytag plus aserpent_king_owner:<uuid>tag pointing back to its husk, for clean orphan detection. - Duplicate defenceIf somehow two husks tagged
serpent_kingend up in the same world (bad backup,/summonabuse, etc.), only the first is wrapped. Duplicates are removed on contact with a warning logged. - Cross-worldIf you run Multiverse or any multi-world setup, each world is fully independent. A boss in
world_netherdoes not know about, interfere with, or contribute to the count inworld_the_end.
The Silent Hunt
One bossbar, only when you're within 300 blocks. No titles. No chat broadcast. No toast.
The Serpent King encounter is communicated almost entirely through in-world cues — sounds, particles, and the visible serpent itself. The single concession to UI is a proximity-gated bossbar that appears only when you're in the same world as the boss and within its 300-block hunt range. Walk out of range and the bar disappears from your HUD. Players in other worlds, or far enough away, never see it. No "ENRAGED!" subtitle pops up at 50% HP. No "VICTORY" banner on death. No global chat message announces the fight.
What the player DOES see
What the player does NOT see
Bossbar mechanics
- RangeVisible to a player iff they're in the same world as the boss and within 300 blocks of it (matching the boss's hunt range — you only see the bar when the boss could engage you).
- Update rateRefreshed every server tick (20 Hz). Players entering range get the bar added; players leaving range get it removed. Diffed against the previous tick — no churn for players already in range.
- ColorPhase 1 — purple. Phase 2 (≤50% HP) — red. Title
The Serpent Kingin dark red, bold. - ProgressTracks
currentHP / maxHP. Updates smoothly as the boss takes damage; the bar drains to empty on death. - Per-world isolationEach Serpent King has its own bossbar keyed by its husk UUID. With Multiverse, two simultaneous Serpent Kings (one per world) get two independent bars. Players in world A never see world B's bar.
- Spectator exclusionPlayers in spectator mode never see the bar even if they're in range — they're observing, not engaging.
- Restart-safeBossbars are registered with namespaced keys; on plugin reload the entity reconstruction reuses the existing registration if present, so bars survive
/reloadcleanly.
Combat Stats
The base entity is an invisible Husk with attribute modifiers applied in the constructor. The invisible flag + scaled block displays create the 300-block visual; the attributes do the actual damage math.
Permanent potion effects
- Strength IApplied at spawn, infinite duration. Upgrades to Strength IV when phase 2 triggers.
- Fire ResistanceApplied at spawn, infinite duration. Immune to fire, lava, and flame enchantments.
- Resistance IIApplied at spawn, infinite duration. Substantial blanket damage reduction on top of the Armor attribute.
Any default Husk equipment (spawn-with-sword chance, etc.) is stripped at spawn — main hand, offhand, and drop chances are all set to AIR / 0. The invisible base never appears armed, and never drops gear on death.
Flight & Movement
Husks do not fly natively — the Serpent King's flight is driven entirely by plugin code. At spawn, the base husk has setGravity(false) so it doesn't fall, and setAI(false) so no pathfinder goal can compete with the manual velocity. Every tick, the plugin computes a normalized direction vector from the boss's position to its target's upper torso and applies it as raw velocity. Block physics stay enabled — the boss collides with terrain, keeping fights grounded in real space.
- GravityDisabled. The husk does not fall. Y-axis movement is entirely under plugin control.
- Pathfinder AIDisabled.
setAI(false)kills every pathfinder goal on the husk. Without this, the RandomStroll, MeleeAttack, and LookAt goals compete withsetVelocity()every tick and produce erratic, stuttering movement. All targeting and velocity logic runs in plugin code instead. - Block collisionEnabled. The boss collides with terrain. If a target ducks behind solid cover, the boss pushes into the surface and hovers until LOS breaks and the target is dropped.
- Movement driverManual
setVelocity()every server tick toward the current target, at the speed dictated by the current phase. - FacingThe entity's yaw and pitch are updated each tick to point at the target, so the dragon-head display doesn't drift sideways.
- Idle behaviourIf no valid target is within 300 blocks (or none with line-of-sight), velocity is zeroed — the boss hovers in place.
- Close-rangeWhen within 3.5 blocks of the target, velocity is zeroed and the boss enters melee mode (see below).
Melee attacks
Vanilla Husk melee is broken on this boss — gravity-off and manual velocity overrides both prevent the mob's MeleeAttackGoal from ever firing (the pathfinder can't "reach" the target because it can't path at all). So the plugin deals damage directly whenever the boss is within attack range, on a fixed cooldown. This is why the boss actually kills things instead of just orbiting them.
- TriggerAny tick in which the boss is within
ATTACK_RANGE(3.5 blocks) of its current target, provided the 20-tick cooldown has elapsed since the last hit. - Damage source
LivingEntity.damage(20.0, baseHusk)— the husk is the attacker for purposes of death messages, knockback direction, and damage tracking. Respects target armour and damage reduction normally. - First hitFires immediately on first contact — the cooldown field is initialised to
-999so there's no startup delay once the boss reaches the player. - Feedback
Sound.ENTITY_WARDEN_ATTACK_IMPACTat volume 1.5 on every landed hit. Players will hear it clearly at close range. - Independent of venomMelee damage and the proximity venom aura are separate systems. A player in melee range gets hit by both on their own timers.
Speed comparison
Flight speed is a raw velocity magnitude (blocks per tick). For reference, a sprint-jumping player moves roughly 0.35 blocks per tick.
Both flight speeds are single-line constants at the top of SerpentKingEntity.java: FLIGHT_SPEED_P1 and FLIGHT_SPEED_P2. Recompile and redeploy to tune.
Phase System
The boss has two phases, triggered by HP threshold. Phase 2 is one-shot — once entered, it cannot be undone, even if the boss is somehow healed back above 50%.
Phase 1 — The Hunt
- Flight speed
0.45blocks/tick - Strength I permanent effect
- Resistance II, Fire Resistance
- Sculk Soul ambient particles every 2s
- Warden roar every 4s
- Venom aura within 8 blocks every 3s
Phase 2 — The Rage
- Flight speed jumps to
0.70blocks/tick - Strength upgrades to Strength IV
- Body palette swaps to a corrupted variant
- Sculk Charge Pop burst at transition
- Warden Sonic Boom sound at transition
- All other effects carry over from phase 1
The "ENRAGED!" title and chat broadcast that used to fire here are gone. The only cues the player receives are in-world: the Sonic Boom sound, the sculk particle burst, the body visibly darkening as its palette swaps to crying obsidian and sculk shriekers — and suddenly the boss catches up to them faster than they can run.
Abilities & Aura
Beyond raw melee damage, the Serpent King projects a venom aura matching the Ancient Serpent's profile. Any survival-mode player within an 8×8×8 cube of the boss gets hit with a triple stack of effects every 3 seconds.
- Range8 blocks in every axis from the invisible base entity (NOT from the visible head — center of the boss).
- Tick rateApplied once every 60 ticks (3 seconds). Effects overlap — standing nearby during an application refreshes the stack.
- Gamemode filterCreative and spectator players are skipped. Adventure-mode players are also skipped for the aura (but still targetable for melee).
- Aura vs meleeThe 20-damage melee attack happens via the vanilla hit animation when the boss is within range. The aura is independent and stacks on top.
Note: unlike the regular Ancient Serpent's melee-hit venom in the Snake plugin, the Serpent King's venom is proximity-based, not contact-based. You don't have to be hit to be poisoned — you just have to be close.
Targeting
Every 10 ticks (plus on the very first tick so there's no initial hover), the boss scans a 300-block radius for the nearest living entity it has line-of-sight to. The Serpent King hunts anything that breathes — but the line-of-sight gate ensures it never locks onto someone hidden behind walls.
The boss calls base.hasLineOfSight(candidate) on every potential target. Blocks between the boss's eye and the candidate cause it to be skipped. This stops the boss from locking onto players sealed in arena waiting rooms, hidden in 3-block-thick bunkers, or otherwise visually obscured. Without this filter, the boss would track and attempt to fly toward unreachable players, looking buggy and wasting flight cycles before the fight even starts.
Once the boss has locked onto a target, it does not drop them just because line-of-sight is briefly obscured. Ducking behind a tree, dropping into a 1-block trench, or running through a doorway will not break aggro. The boss only abandons its current target when that target dies, leaves the world, leaves the 300-block hunt range, or switches to creative/spectator. To genuinely break aggro mid-fight you have to put real distance between yourself and the boss.
Will hunt
- Players in Survival or Adventure mode
- Every snake from the Snake plugin (Corn Snake through Ancient Serpent)
- Hostile mobs — zombies, skeletons, creepers, phantoms, etc.
- Passive mobs — cows, sheep, pigs, villagers, animals
- Raiders, piglins, guardians, anything
LivingEntity
Will ignore
- Players in Creative or Spectator mode
- Itself (tagged
serpent_king) - Any other Serpent Kings
- Anything without line-of-sight to the boss at acquisition time
- Silverfish (SnakeBedrockBridge proxies — would lock the boss to "self")
- Non-living entities — items, armor stands, block displays, arrows
- Its own segment displays (
serpent_king_displaytag)
- Range300 blocks from the base entity, cubic volume.
- Scan frequencyEvery 10 ticks (0.5 seconds), plus tick 1 so there's no idle spin-up.
- LOS checkUses Paper's
LivingEntity.hasLineOfSight(Entity), which ray-casts from the boss's eye to the candidate. Blocks like fences and glass panes follow vanilla's block-opacity rules — generally LoS-transparent, so a player crouching behind a fence is still visible. Solid blocks (stone, dirt, doors) reliably break LoS. - TiebreakNearest LOS-visible candidate wins by squared distance.
- Target stickinessOnce acquired, target is held until death, world-leave, range-leave, or gamemode switch to creative/spectator. Brief LoS loss does not break aggro. This is the deliberate trade — sealed players never get targeted, but a real fight doesn't get cheap-cancelled by ducking behind cover.
- Re-acquireWhen the boss has no current target, the next 10-tick retarget scans for a new one with a strict LoS check. So a player who has been hiding behind cover since spawn is never acquired in the first place — the boss either picks someone visible or idles.
- Idle behaviourNo valid target → the boss enters its idle wander pattern (random scouting flights with altitude soft-cap) until something becomes visible.
- Ancient Serpent?Yes — it's a snake and a living entity. A Serpent King summoned in the Deep Dark with an active Ancient Serpent nearby will result in the two actually fighting each other, assuming they have LoS.
Gallery
Screenshots of the Serpent King in worlds it has visited — sculk-pattern body, deepslate accents, and the phase-2 corruption palette. Click any image to view full size; arrow keys navigate, Esc or click outside closes.
Appearance
Visually, the Serpent King is a supersized version of the Ancient Serpent. Same base render pipeline — invisible base entity plus block displays — but scaled up across the board.
Body palette — Ancient-Serpent family
The body rotates through six materials, identical to the Ancient Serpent's deep-dark palette, so the two read as the same species lineage.
Phase 2 palette — the Corruption
At ≤50% HP, every segment's block is swapped to the phase-2 palette. The head stays a dragon head; only the body changes. The new materials keep the dark sculk-family feel but introduce crying obsidian (violet weeping tears) and sculk shriekers (orange warning rings) to signal the boss is scarred and dangerous.
The palette is a single Material[] constant named BODY_PALETTE_P2 at the top of SerpentKingEntity.java. Swap its six entries for MAGMA_BLOCK, RED_NETHER_BRICKS, CRYING_OBSIDIAN, etc. to restore the original fiery phase 2 look — no other code needs to change.
Structural details
- HeadA single
BlockDisplayrendering aDRAGON_HEADblock at 5× scale, oriented south at spawn. Teleported to the base entity's position every tick. - Body80
BlockDisplayentities, one per segment. On every tick, each segment is teleported to a position along the boss's recent movement trail, creating a snake-like following motion. - Trail mathA location-history deque stores up to 5000 recent positions. Segments are placed by walking the trail and interpolating at fixed 3.5-block intervals — so the body flows through space even during fast turns.
- Self-healingIf the head display is removed (WorldEdit,
/kill @e, etc.), the boss rebuilds all displays from scratch on the next tick. - Orphan cleanupOn plugin enable, any entity tagged
serpent_king_displayfrom a previous run is removed — prevents ghost displays after a crash or forced shutdown.
Sounds & Particles
Because there is no bossbar, atmosphere is everything. Every audio and particle cue is intentional — it's the only way the game tells the player what's happening.
Ambient loop
- Every 40t (2s)
Particle.SCULK_SOUL— 40 particles in a 3-block cube around the boss, 2 blocks above the base. - Every 80t (4s)
Sound.ENTITY_WARDEN_ROAR— volume 2.0, pitch 0.45 (deep). Audible from hundreds of blocks away.
Event cues
- Spawn
Sound.ENTITY_ENDER_DRAGON_GROWLat spawn location, volume 3.0, pitch 0.5. - Phase 2 trigger
Particle.SCULK_CHARGE_POP× 60 at the boss's head area, plusSound.ENTITY_WARDEN_SONIC_BOOMat volume 2.0, pitch 0.8. This is the "oh no" moment. - DeathNo custom effects — the vanilla Husk death animation and sound play. No toast-sound, no title, no chat.
Drops on Kill
When the boss dies, it drops exactly what a vanilla Husk drops — nothing more. There is no custom reward system: no nether stars, no dragon eggs, no inventory-push to every online player. The Serpent King lives and dies like any other mob.
On death, standard Bukkit/Paper drop rules apply: rotten flesh (0–2), a small chance of carrots, potatoes, or iron ingots, and vanilla XP. Looting enchantments on the killing weapon modify drop counts normally.
- Custom dropsNone. The plugin does not touch
EntityDeathEvent.getDrops()beyond the standard tracking for removing the boss from its world slot. - XPVanilla husk XP — modest, not scaled to match the boss's 2000 HP. If you want the boss to be a worthwhile XP farm, that's a configuration change you'd layer on top.
- No broadcastNo chat message, no title, no toast — the boss simply stops existing. Its displays are cleaned up automatically on the same tick.
- World slotThe per-world boss slot is released immediately, so a fresh
/spawnbossin the same world works right away.
Add back a drops block inside SerpentKingPlugin.onEntityDeath — event.getDrops().clear() followed by event.getDrops().add(new ItemStack(...)) for each item you want. The old "Nether Star + Dragon Egg + Elytra + 64 XP bottles" configuration is in the git history if you ever want it back.
Admin Commands
All three commands require the serpentking.admin permission (granted to operators by default). The plugin defines no other commands.
From console,
/killboss removes every active Serpent King across every world and reports the total count.Console can run it only if there is exactly one active boss server-wide — otherwise it replies asking you to run from a player.
Permission node
- serpentking.adminGrants access to all three commands. Default:
op(server operators have it automatically). Revoke via your permissions plugin of choice to lock the commands.