Esempio n. 1
0
            public PlayerEventListener(Player player, bool isOpponent)
            {
                _backendFacade = GameClient.Get <BackendFacade>();
                _backendDataControlMediator = GameClient.Get <BackendDataControlMediator>();
                IDataManager dataManager = GameClient.Get <IDataManager>();

                Player     = player;
                IsOpponent = isOpponent;

                if (!dataManager.BetaConfig.SaveTurnData)
                {
                    return;
                }

                Player.TurnEnded            += TurnEndedHandler;
                Player.TurnStarted          += TurnStartedHandler;
                Player.PlayerHpChanged      += PlayerHpChangedHandler;
                Player.PlayerGooChanged     += PlayerGooChangedHandler;
                Player.PlayerVialGooChanged += PlayerVialGooChangedHandler;
                Player.DeckChanged          += DeckChangedHandler;
                Player.HandChanged          += HandChangedHandler;
                Player.GraveyardChanged     += GraveyardChangedHandler;
                Player.BoardChanged         += BoardChangedHandler;
                Player.CardPlayed           += CardPlayedHandler;
            }
Esempio n. 2
0
 public void Init()
 {
     _dataManager   = GameClient.Get <IDataManager>();
     _backendFacade = GameClient.Get <BackendFacade>();
 }