Skip to content

fix: minecraft block drivers spawner, beacon, jukebox, note block, death messages (BUG-092-095, BUG-097)#70

Open
ximaks00-hue wants to merge 1 commit into
akki697222:dev-MC1.20from
ximaks00-hue:fix/bug-092-097-minecraft-drivers
Open

fix: minecraft block drivers spawner, beacon, jukebox, note block, death messages (BUG-092-095, BUG-097)#70
ximaks00-hue wants to merge 1 commit into
akki697222:dev-MC1.20from
ximaks00-hue:fix/bug-092-097-minecraft-drivers

Conversation

@ximaks00-hue

Copy link
Copy Markdown
Contributor

Summary

  • BUG-092: SpawnerBlockEntity.getSpawner().save(tag) — CE cast tile entity to BaseSpawner causing ClassCastException on getSpawningMobName().
  • BUG-093: Null-check MobEffect before ForgeRegistries.getKey — NPE when beacon has no effect configured.
  • BUG-094: Jukebox stop() uses level event 1011 (SOUND_STOP_JUKEBOX_SONG); CE sent 1010 with id 0 which does not stop playback.
  • BUG-095: Always fire note block event; return canTrigger (air above) as informational — Original called triggerNote unconditionally.
  • BUG-097: Guard .player death message variant with Language.getInstance.has() — matches Original I18n.hasKey to avoid raw translation keys.

Test plan

  • Lua mob_spawner.getSpawningMobName() on spawner — no crash, correct entity id
  • Beacon with no secondary effect — getSecondaryEffect() returns nil not NPE
  • Jukebox stop() while playing — music stops
  • Note block with block above — still plays (different instrument)
  • Nanomachine overload death with damager — valid death message text

…ath messages (BUG-092-095, BUG-097)

BUG-092: SpawnerBlockEntity.getSpawner().save() instead of invalid BaseSpawner cast on tile entity.

BUG-093: Null-check MobEffect before ForgeRegistries lookup to avoid NPE on empty beacon effects.

BUG-094: Jukebox stop uses level event 1011 (SOUND_STOP_JUKEBOX_SONG) not 1010 play with id 0.

BUG-095: Always fire note block event; return canTrigger as informational like Original triggerNote.

BUG-097: Guard .player death message variant with Language.has() matching Original I18n.hasKey.
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.

2 participants