Class PlayerLobbyStateService

java.lang.Object
dev.deepcore.challenge.session.PlayerLobbyStateService

public final class PlayerLobbyStateService extends Object
Handles player game-mode enforcement and lobby loadout application.
  • Constructor Details

    • PlayerLobbyStateService

      public PlayerLobbyStateService(WorldClassificationService worldClassificationService, PrepBookService prepBookService)
      Creates a player lobby state service.
      Parameters:
      worldClassificationService - world classification helper
      prepBookService - prep book inventory helper
  • Method Details

    • enforceSurvivalOnWorldEntry

      public void enforceSurvivalOnWorldEntry(org.bukkit.entity.Player player, boolean runningPhase, boolean hardcoreEnabled, Set<UUID> eliminatedPlayers)
      Enforces survival mode on world entry for non-eliminated participants.
      Parameters:
      player - player whose game mode should be normalized
      runningPhase - whether the challenge is currently running
      hardcoreEnabled - whether hardcore mode is enabled
      eliminatedPlayers - UUIDs of eliminated players
    • applyLobbyInventoryLoadoutIfInLobbyWorld

      public void applyLobbyInventoryLoadoutIfInLobbyWorld(org.bukkit.entity.Player player)
      Applies lobby inventory loadout when the player is in a lobby/limbo world.
      Parameters:
      player - player whose inventory should be reset for lobby state