PlayerSettings() public method

public PlayerSettings ( byte playerId, bool invertedTable, bool spectator ) : void
playerId byte
invertedTable bool
spectator bool
return void
Example #1
0
        public void PlayerSettings(byte player, bool invertedTable)
        {
            PlayerInfo p;

            // The player may have left the game concurently
            if (!_players.TryGetValue(player, out p))
            {
                return;
            }
            p.InvertedTable = invertedTable;
            _broadcaster.PlayerSettings(player, invertedTable);
        }
Example #2
0
        public void PlayerSettings(byte player, bool invertedTable)
        {
            PlayerInfo p;

            // The player may have left the game concurrently
            p = State.Instance.Players.FirstOrDefault(x => x.Id == player);
            if (p == null)
            {
                return;
            }
            p.InvertedTable = invertedTable;
            _broadcaster.PlayerSettings(player, invertedTable);
        }
Example #3
0
        public void PlayerSettings(byte player, bool invertedTable, bool spectator)
        {
            if (this.GameStarted)
            {
                return;
            }
            PlayerInfo p;

            // The player may have left the game concurrently
            p = State.Instance.Players.FirstOrDefault(x => x.Id == player);
            if (p == null)
            {
                return;
            }
            if (p.InvertedTable != invertedTable || p.IsSpectator != spectator)
            {
                p.InvertedTable = invertedTable;
                p.IsSpectator   = spectator;
                _broadcaster.PlayerSettings(player, invertedTable, spectator);
            }
        }