using System; namespace LobbyRelaySample { /// /// Current state of the local Game. /// Set as a flag to allow for the unity inspector to select multiples for various UI features. /// [Flags] public enum GameState { Menu = 1, Lobby = 2, JoinMenu = 4, } /// /// Awaits player input to change the local game Data /// [System.Serializable] public class LocalGameState : Observed { GameState m_State = GameState.Menu; public GameState State { get => m_State; set { m_State = value; OnChanged(this); } } public override void CopyObserved(LocalGameState oldObserved) { m_State = oldObserved.State; OnChanged(this); } } }