Klasse WaveSetRegistry

java.lang.Object
de.delinkedde.mobarenareborn.wave.WaveSetRegistry

public final class WaveSetRegistry extends Object
Loads and holds the configured wave sets from waves.yml.

On first run the bundled default waves.yml is written to the data folder. Each entry is parsed by WaveSet.fromSection(String, ConfigurationSection); malformed entries are skipped with a warning. resolve(String) returns the requested set or the built-in default when it is missing, so an arena always has a usable roster.

  • Konstruktordetails

    • WaveSetRegistry

      public WaveSetRegistry(@NotNull @NotNull MobArenaPlugin plugin)
      Parameter:
      plugin - the owning plugin
  • Methodendetails

    • load

      public void load()
      Loads (or reloads) all wave sets from waves.yml, writing the default file if absent.
    • resolve

      @NotNull public @NotNull WaveSet resolve(@NotNull @NotNull String name)
      Resolves a wave set by name, falling back to the default set when it is missing.
      Parameter:
      name - the wave-set identifier
      Gibt zurück:
      the matching wave set, or the default