Skip to content

Reward sounds: the Sound editor lists unusable entries and upper-case sound names fail silently #392

In review

Description

@andrewkm

Versions

  • AdvancedCore 3.8.2-SNAPSHOT (master at 04a0eb9), as shaded in VotingPlugin 7.2-SNAPSHOT
  • Paper 26.3 (build 264)

What happens

  1. The in-game reward editor's Sound page offers unusable choices. Each entry is the sound object's debug text (CraftSound{holder=...}) instead of a sound name, and picking one saves that text as Sound.Sound, so the reward then plays nothing.
  2. A reward sound written the old way, such as Sound: 'ENTITY_PLAYER_LEVELUP' (or BLOCK_NOTE_BLOCK_CHIME as in Playsound is not working VotingPlugin#1417), plays nothing and logs nothing at the normal log level. Only the bare lower-case key works (entity.player.levelup, as in the bundled ExampleAdvanced.yml); a minecraft: prefix fails as well. With debug enabled, the only traces are the NamespacedKey exception and the line Invalid sound: ENTITY_PLAYER_LEVELUP.

Cause

Expected

  • The Sound editor lists the sound keys (for example entity.player.levelup), the format playback accepts.
  • An unknown sound name in a reward is reported at the normal log level, the way playParticle logs Failed to create particle, so a misconfigured reward is visible.
  • Optionally, old enum-style names keep working by matching them against the registry keys with dots read as underscores (block.note_block.chime and BLOCK_NOTE_BLOCK_CHIME). Replacing every _ with ., as the click-sound option does, cannot resolve names whose key itself contains an underscore.

To reproduce

  1. In a reward file set

    Sound:
      Enabled: true
      Sound: 'ENTITY_PLAYER_LEVELUP'

    and run the reward (for example with a test vote): no sound, and nothing in the console.

  2. Change it to 'entity.player.levelup' and run it again: the sound plays.

  3. Open the in-game reward editor's Sound page and look at the Sound.Sound choices.

Activity

  1. BenCodez commented on Nov 28, 2026

    @BenCodez
    Owner

    Wanna test the latest dev build?

  2. andrewkm commented on Nov 28, 2026

    @andrewkm
    Author

    Thanks for the quick fix! I read through #393 and it covers all three points: the editor lists the registry keys, an unknown name now logs a warning, and the old enum-style names resolve without breaking keys that contain underscores (and minecraft: keys work too).

    Happy to test. The newest advancedcore 3.8.2-SNAPSHOT on your Nexus is build 149 from Nov 24, and votingplugin 7.2-SNAPSHOT is from earlier today, both from before the merge, so I can't pick the change up from there yet. Where can I grab the dev build, or could you publish a snapshot? I'll test the editor and an old-style sound name in game and report back.

  3. BenCodez commented on Nov 28, 2026

    @BenCodez
    Owner

    right here https://bencodez.com/job/VotingPlugin/

    snapshot also posted.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions