コード例 #1
0
 public static void forceIndexWinner(RoundID id, int index)
 {
     Msf.Connection.SendMessage((short)CustomMasterServerMSG.tournamentRoundForceWinner, new TournamentForceWinnerMessage()
     {
         tournamentID = singleton.tournamentInfo.tournamentID, roundID = id, winIndex = index
     });
 }
コード例 #2
0
        public static void handleGameResult(string tournamentID, RoundID roundID, GameOverMsg result)
        {
            RunningTournamentGame game;

            if (singleton.findGame(tournamentID, out game))
            {
                game.reportRoundResult(roundID, result);
            }
        }
コード例 #3
0
        private void startGame(RoundID id)
        {
            if (runningTournament == false)
            {
                return;
            }

            Msf.Connection.SendMessage((short)CustomMasterServerMSG.tournamentRoundStarted, new TournamentPreGameInfo()
            {
                tournamentID = tournamentInfo.tournamentID, roundID = id
            });
        }
コード例 #4
0
        private void openRoundLobby(RoundID id, bool forceRestart = false)
        {
            if (runningTournament == false)
            {
                return;
            }

            Msf.Connection.SendMessage((short)CustomMasterServerMSG.tournamentRoundPreStarted, new TournamentPreGameInfo()
            {
                tournamentID = tournamentInfo.tournamentID, roundID = id, forceRestart = forceRestart
            });
        }
コード例 #5
0
        private void updateRound(string tournamentID, RoundID roundID)
        {
            RunningTournamentGame game;

            if (findGame(tournamentID, out game))
            {
                game.updateRound(roundID);
            }
            else
            {
                Debug.LogError("Did not find game: " + tournamentID + " for round " + roundID.col + "." + roundID.row);
            }
        }
コード例 #6
0
 public void init(TournamentRound serverRound, RoundType type)
 {
     this.serverRound = serverRound;
     this.type        = type;
     id            = serverRound.getGameID();
     players       = serverRound.getPlayers();
     state         = serverRound.getState();
     preGameRoomID = serverRound.preGameRoomID;
     initPlayerSlotTypes();
     setPlayerSlots();
     initClicks();
     initPlayerSlots();
 }
コード例 #7
0
 public static void handleUpdateRound(string tournamentID, RoundID roundID)
 {
     singleton.updateRound(tournamentID, roundID);
 }
コード例 #8
0
 public static void forceRestartRoundLobby(RoundID id)
 {
     singleton.openRoundLobby(id, true);
 }
コード例 #9
0
 public static void startRoundLobby(RoundID id)
 {
     singleton.openRoundLobby(id);
 }
コード例 #10
0
 public static void startRoundGame(RoundID id)
 {
     singleton.startGame(id);
 }