Beispiel #1
0
            void ShowResult()
            {
                statusData.State = BattleResult;
                if (_state.winningPlayer == _client.GetSessionId())
                {
                    winnerOptionDialog.Show(Rematch, Leave);
                }
                else
                {
                    loserOptionDialog.Show(Rematch, Leave);
                }

                void Rematch()
                {
                    _client.SendRematch(true);
                    statusData.State = WaitingOpponentRematchDecision;
                }

                void Leave()
                {
                    _client.SendRematch(false);
                    LeaveGame();
                }
            }