Exemplo n.º 1
0
        public override void AddedTo(DeckLocation location, Player player)
        {
            base.AddedTo(location, player);

            switch (location)
            {
            case DeckLocation.InPlay:
                if (_PhaseChangingEventHandler != null)
                {
                    player.PhaseChanging -= _PhaseChangingEventHandler;
                }

                _PhaseChangingEventHandler = new Player.PhaseChangingEventHandler(player_PhaseChanging);
                player.PhaseChanging      += _PhaseChangingEventHandler;

                if (_CleaningUpEventHandler != null)
                {
                    player.CleaningUp -= _CleaningUpEventHandler;
                }

                _CleaningUpEventHandler = new Player.CleaningUpEventHandler(player_CleaningUp);
                player.CleaningUp      += _CleaningUpEventHandler;

                _CanPutOnDeck = false;
                break;
            }
        }
Exemplo n.º 2
0
 public override void RemovedFrom(DeckLocation location, Player player)
 {
     base.RemovedFrom(location, player);
     if (_PhaseChangingEventHandler != null)
     {
         player.PhaseChanging -= _PhaseChangingEventHandler;
     }
     _PhaseChangingEventHandler = null;
     if (_CleaningUpEventHandler != null)
     {
         player.CleaningUp -= _CleaningUpEventHandler;
     }
     _CleaningUpEventHandler = null;
     _CanPutOnDeck           = false;
 }
Exemplo n.º 3
0
		public override void RemovedFrom(DeckLocation location, Player player)
		{
			base.RemovedFrom(location, player);
			if (_PhaseChangingEventHandler != null)
				player.PhaseChanging -= _PhaseChangingEventHandler;
			_PhaseChangingEventHandler = null;
			if (_CleaningUpEventHandler != null)
				player.CleaningUp -= _CleaningUpEventHandler;
			_CleaningUpEventHandler = null;
			_CanPutOnDeck = false;
		}
Exemplo n.º 4
0
		public override void AddedTo(DeckLocation location, Player player)
		{
			base.AddedTo(location, player);

			switch (location)
			{
				case DeckLocation.InPlay:
					if (_PhaseChangingEventHandler != null)
						player.PhaseChanging -= _PhaseChangingEventHandler;

					_PhaseChangingEventHandler = new Player.PhaseChangingEventHandler(player_PhaseChanging);
					player.PhaseChanging += _PhaseChangingEventHandler;

					if (_CleaningUpEventHandler != null)
						player.CleaningUp -= _CleaningUpEventHandler;

					_CleaningUpEventHandler = new Player.CleaningUpEventHandler(player_CleaningUp);
					player.CleaningUp += _CleaningUpEventHandler;

					_CanPutOnDeck = false;
					break;
			}
		}