Skip to content

Spawn custom-blocks bosses and spawners on the current tick#493

Merged
tastybento merged 1 commit intodevelopfrom
feature/faster-custom-spawns
Apr 8, 2026
Merged

Spawn custom-blocks bosses and spawners on the current tick#493
tastybento merged 1 commit intodevelopfrom
feature/faster-custom-spawns

Conversation

@tastybento
Copy link
Copy Markdown
Member

Two independent delays made block-placed spawners and mythic-mob bosses feel sluggish, appearing ~1-2 seconds after the magic block broke. Remove both:

  1. MythicMobCustomBlock now prefers the 4-arg spawnMythicMob(record, loc, Consumer, long) overload from BentoBox 3.15.0+ with delayTicks=0, so the boss spawns on the current tick instead of after the hook's historical 40-tick (2s) delay. That delay exists for blueprint-paste callers and is dead time for AOneBlock's synchronous block replace. Reflection falls back to the 3-arg (40-tick) and 2-arg overloads on older BentoBox, so nothing breaks for users running BentoBox 3.13-3.14. MakeSpace still runs from the Consumer callback.

  2. The example spawner NBT in the README and 0_plains.yml used Delay:20 (first spawn in 1s); switch to Delay:0 so the first spawn happens on the next tick (visually instant). Extend the "Spawner gotcha" callout with one sentence explaining Delay:0 vs Delay:N vs Delay:-1.

Companion BentoBox PR adds the 4-arg overload; until that release lands, the reflection fallback keeps behaviour identical to today.

Two independent delays made block-placed spawners and mythic-mob
bosses feel sluggish, appearing ~1-2 seconds after the magic block
broke. Remove both:

1. MythicMobCustomBlock now prefers the 4-arg
   spawnMythicMob(record, loc, Consumer, long) overload from BentoBox
   3.15.0+ with delayTicks=0, so the boss spawns on the current tick
   instead of after the hook's historical 40-tick (2s) delay. That
   delay exists for blueprint-paste callers and is dead time for
   AOneBlock's synchronous block replace. Reflection falls back to
   the 3-arg (40-tick) and 2-arg overloads on older BentoBox, so
   nothing breaks for users running BentoBox 3.13-3.14. MakeSpace
   still runs from the Consumer callback.

2. The example spawner NBT in the README and 0_plains.yml used
   Delay:20 (first spawn in 1s); switch to Delay:0 so the first
   spawn happens on the next tick (visually instant). Extend the
   "Spawner gotcha" callout with one sentence explaining Delay:0 vs
   Delay:N vs Delay:-1.

Companion BentoBox PR adds the 4-arg overload; until that release
lands, the reflection fallback keeps behaviour identical to today.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@tastybento tastybento merged commit c568185 into develop Apr 8, 2026
@tastybento tastybento deleted the feature/faster-custom-spawns branch April 8, 2026 20:31
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Apr 8, 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant