SwornHeroWiki
Configuration

Selection modes

How RANDOM, NO_REPEAT, and SHUFFLE_BAG choose greetings.

Set the mode with selection.mode.

RANDOM

Performs weighted random selection using each message’s weight.

When avoidImmediateRepeats is true and another message is available, the previously selected entry is excluded from the candidate list.

NO_REPEAT

Uses weighted random selection while always preventing the same message from being selected twice consecutively when another message is available.

This is equivalent to RANDOM with immediate-repeat avoidance forced on.

SHUFFLE_BAG

Places every configured message into a randomized bag and uses each one before refilling.

  • Every entry appears once during a complete cycle.
  • Weights influence the order in which entries enter the bag; they do not cause an entry to appear multiple times in one cycle.
  • When avoidImmediateRepeats is enabled and the newly filled bag would start with the previous message, the first two entries are swapped when possible.

Per-player vs shared history

SettingBehavior
rememberPerPlayer: trueEach player has independent last-message / shuffle-bag state.
rememberPerPlayer: falseThe pool shares one selection state across the server.

Preview and simulation use separate pool keys (preview:* and simulation:*), so they do not advance the normal join selection history for that player.

Lifetime of selection state

Selection state is stored in memory only. It resets when:

  • the server restarts
  • /joingreetings reload succeeds

First-time player history remains persistent and is unrelated to selection state.

Found a problem in these docs? Report a documentation issue on GitHub.

On this page