Skip to content

Sein Lobby State

Class · ASeinLobbyState : AActor

#include "SeinLobbyState.h"

Replicated lobby state actor. Server spawns one at first PostLogin; bAlwaysRelevant = true ensures every connected client receives the slot array via OnRep_Slots. Mutation is server-only and routed through USeinLobbySubsystem (validates + commits). Lobby widgets bind to OnLobbyStateChanged.

Read-only accessor: copy of the current slot array. Safe to call from BP.

const TArray<FSeinLobbySlotState>& GetSlots() const;

TArray<FSeinLobbySlotState> Slots

Blueprint read-only

Replicated per-slot state. Server is the single writer; clients mirror via OnRep_Slots.

TSoftObjectPtr<UWorld> SelectedMap

Blueprint read-only

Lobby’s currently-selected gameplay map (host’s pick from the map dropdown). Drives:

  • Slot count (lobby resizes to the entry’s SlotCount on selection)

  • StartMatch ServerTravel destination Replicated so every client’s UI shows the same selection.

void OnRep_Slots();

Runs on clients when the slot list replicates, and raises the lobby state changed event so lobby widgets refresh.

void OnRep_SelectedMap();

Runs on clients when the selected map replicates, and raises the lobby state changed event so lobby widgets refresh.

C++ members (2)
  • const FSeinLobbySlotState* FindSlot(int32 SlotIndex) const; Lookup by slot index (1-based). Returns nullptr if not present.
  • FSeinLobbySlotState* FindSlotMutable(int32 SlotIndex);