Exemple #1
0
        public void Initialize(Game game)
        {
            Game = game;
            Id   = game.Recorder.CreateId(this);

            _life.Initialize(ChangeTracker);
            _landsPlayedCount.Initialize(ChangeTracker);
            _hasMulligan.Initialize(ChangeTracker);
            _hasLost.Initialize(ChangeTracker);
            _isActive.Initialize(ChangeTracker);
            _hasPriority.Initialize(ChangeTracker);
            ManaCache.Initialize(ChangeTracker);
            _modifiers.Initialize(ChangeTracker);
            _continiousEffects.Initialize(null, Game);
            _landLimit.Initialize(Game, null);
            _battlefield.Initialize(Game);
            _hand.Initialize(Game);
            _graveyard.Initialize(Game);
            _library.Initialize(Game);
            _exile.Initialize(Game);
            _skipSteps.Initialize(ChangeTracker);
            _emblems.Initialize(ChangeTracker);

            LoadLibrary();
        }
Exemple #2
0
        public void Initialize(Game game)
        {
            Game = game;

            _attackers.Initialize(game.ChangeTracker);
            _blockers.Initialize(game.ChangeTracker);
        }
Exemple #3
0
        public virtual void Initialize(Game game, IHashDependancy hashDependancy)
        {
            Game = game;

            _modifiers.Initialize(game.ChangeTracker);
            _currentValue.Initialize(game.ChangeTracker, hashDependancy);
        }
Exemple #4
0
        public void Initialize(Game game)
        {
            Game = game;

            _effects.Initialize(ChangeTracker);
            _lastResolved.Initialize(ChangeTracker);
            _triggeredEffects.Initialize(ChangeTracker);
        }
Exemple #5
0
        public void Initialize(Game game)
        {
            Game = game;

            _extraTurns.Initialize(ChangeTracker);
            Player1.Initialize(Game);
            Player2.Initialize(Game);
        }
Exemple #6
0
        public void Initialize(Card owningCard, Game game)
        {
            _combatRules.Initialize(game.ChangeTracker);

            foreach (var combatRule in _combatRules)
            {
                combatRule.Initialize(owningCard, game);
            }
        }
        public void Initialize(Card card, Game game)
        {
            _abilities.Initialize(game.ChangeTracker, card);

            foreach (var activatedAbility in _abilities)
            {
                activatedAbility.Initialize(card, game);
            }
        }
Exemple #8
0
        public Attacker(Card card, Game game)
        {
            Game  = game;
            _card = card;

            _blockers.Initialize(ChangeTracker);
            _assignedDamage.Initialize(ChangeTracker);
            _isBlocked.Initialize(ChangeTracker);
        }
Exemple #9
0
        public Attacker(Card card, Card planeswalker, Game game)
        {
            Game          = game;
            _card         = card;
            _planeswalker = planeswalker;

            _blockers.Initialize(ChangeTracker);
            _isBlocked.Initialize(ChangeTracker);
        }
Exemple #10
0
        public void Initialize(INotifyChangeTracker changeTracker)
        {
            foreach (var managroup in _groups)
            {
                managroup.Initialize(changeTracker);
            }

            _manaPool.Initialize(changeTracker);
            _removeList.Initialize(changeTracker);
        }
Exemple #11
0
        public override void Initialize(Card owningCard, Game game)
        {
            base.Initialize(owningCard, game);

            _p.ManaOutput.Initialize(this, game);
            _units.Initialize(ChangeTracker);
            _manaCache = owningCard.Controller.ManaCache;

            SubscribeToEvents();
        }
Exemple #12
0
        public void Initialize(Card source, Game game)
        {
            Game = game;

            _continiousEffects.Initialize(ChangeTracker);

            foreach (var continiousEffect in _continiousEffects)
            {
                continiousEffect.Initialize(source, Game);
            }
        }
Exemple #13
0
        public Blocker(Card card, Attacker attacker, Game game)
        {
            Card = card;
            Game = game;

            _attacker = new Trackable <Attacker>(attacker);
            _attacker.Initialize(ChangeTracker);

            _assignedDamage.Initialize(ChangeTracker);
            _damageAssignmentOrder.Initialize(ChangeTracker);
        }
Exemple #14
0
        public void Initialize(Card card, Game game)
        {
            Game = game;

            _abilities.Initialize(game.ChangeTracker, card);

            foreach (var triggeredAbility in _abilities)
            {
                triggeredAbility.Initialize(card, game);
            }
        }
Exemple #15
0
        public void Initialize(Game game)
        {
            Game = game;

            _attackers.Initialize(ChangeTracker);
            _blockers.Initialize(ChangeTracker);
            _changedZone.Initialize(ChangeTracker);
            _damaged.Initialize(ChangeTracker);
            _hasAnythingBeenPlayedOrActivatedDuringThisStep.Initialize(ChangeTracker);
            _hasActivePlayerPlayedAnySpell.Initialize(ChangeTracker);
        }
Exemple #16
0
        public void Initialize(IHashDependancy hashDependancy, Game game)
        {
            Game = game;

            _all.Initialize(ChangeTracker, hashDependancy);

            foreach (var staticAbility in _all)
            {
                staticAbility.Initialize(ChangeTracker);
            }

            _active.Initialize(ChangeTracker);
        }
Exemple #17
0
        public Card Initialize(Player owner, Game game)
        {
            Game  = game;
            Owner = owner;
            Id    = game.Recorder.CreateId(this);

            JoinedBattlefield.Initialize(ChangeTracker);
            LeftBattlefield.Initialize(ChangeTracker);

            _base.Initialize(game, this);
            _controller = new CardController(owner);
            _controller.Initialize(game, this);

            _strenght.Initialize(game, this);
            _level.Initialize(game, this);
            _combatCost.Initialize(game, this);
            _counters.Initialize(this, game);
            _typeOfCard.Initialize(game, this);
            _colors.Initialize(game, this);
            _protections.Initialize(game, this);
            _zone.Initialize(ChangeTracker, this);
            _modifiers.Initialize(ChangeTracker);

            _isTapped.Initialize(ChangeTracker, this);
            _attachedTo.Initialize(ChangeTracker, this);
            _attachments.Initialize(ChangeTracker, this);
            _hasRegenerationShield.Initialize(ChangeTracker, this);
            _damage.Initialize(ChangeTracker, this);
            _hasLeathalDamage.Initialize(ChangeTracker, this);
            _hasSummoningSickness.Initialize(ChangeTracker, this);
            _hash.Initialize(ChangeTracker);
            _isHidden.Initialize(ChangeTracker, this);
            _isRevealed.Initialize(ChangeTracker, this);
            _isPeeked.Initialize(ChangeTracker, this);
            _usageScore.Initialize(ChangeTracker, this);

            _base.Value.Initialize(this, Game);

            _castRules.Initialize(this, game);
            _simpleAbilities.Initialize(this, game);
            _triggeredAbilities.Initialize(this, game);
            _activatedAbilities.Initialize(this, game);
            _staticAbilities.Initialize(this, game);
            _combatRules.Initialize(this, game);


            _minimumBlockerCount.Initialize(Game, null);
            _isPreview = false;

            return(this);
        }
Exemple #18
0
        public void Initialize(Card source, Game game, Effect sourceEffect = null)
        {
            Game = game;

            _doNotUpdate.Initialize(ChangeTracker);
            _modifiers.Initialize(ChangeTracker);
            _isActive.Initialize(ChangeTracker);

            Source       = source;
            SourceEffect = sourceEffect;

            Subscribe(this);
            SubscribeToEvents();
        }
Exemple #19
0
        private void Initialize()
        {
            Stack.Initialize(this);
            Turn.Initialize(this);
            _wasStopped.Initialize(ChangeTracker);
            Combat.Initialize(this);
            _decisionQueue.Initialize(this);
            _stateMachine.Initialize(this, _decisionQueue);
            Players.Initialize(this);

            _damageRedirections.Initialize(ChangeTracker);
            _damagePreventions.Initialize(ChangeTracker);
            _costModifiers.Initialize(ChangeTracker);
            _modifiers.Initialize(ChangeTracker);
        }
Exemple #20
0
        public void Initialize(Card owningCard, Game game)
        {
            Game       = game;
            OwningCard = owningCard;
            _lifetimes.Initialize(game.ChangeTracker);
            _isEnabled.Initialize(game.ChangeTracker);

            if (_enabledInAllZones)
            {
                Enable();
            }

            Subscribe(this);
            SubscribeToEvents();
        }
Exemple #21
0
        public void Initialize(Card owningCard, Game game)
        {
            Game       = game;
            OwningCard = owningCard;

            _lifetimes.Initialize(ChangeTracker);
            _isEnabled.Initialize(ChangeTracker);
            _isActivated.Initialize(ChangeTracker);

            if (_enabledInAllZones || owningCard.Zone == Zone.Battlefield)
            {
                Enable();
            }

            Subscribe(this);
            SubscribeToEvents();
        }
Exemple #22
0
 public void Initialize(INotifyChangeTracker changeTracker)
 {
     _preventions.Initialize(changeTracker);
 }
Exemple #23
0
 public void Initialize(ChangeTracker changeTracker)
 {
     _redirections.Initialize(changeTracker);
 }
        public void Initialize(Card source, Game game)
        {
            Game = game;

            _continiousEffects.Initialize(ChangeTracker);
        }
Exemple #25
0
 public void Initialize(ChangeTracker changeTracker)
 {
     _assigned.Initialize(changeTracker);
 }
Exemple #26
0
 protected override void Initialize()
 {
     _aurasQueue.Initialize(ChangeTracker);
 }
Exemple #27
0
 public void Initialize(ChangeTracker changeTracker)
 {
     _costModifiers.Initialize(changeTracker);
 }
Exemple #28
0
 public virtual void Initialize(Game game)
 {
     Game = game;
     _cards.Initialize(ChangeTracker);
 }
Exemple #29
0
 public void Initialize(Game game)
 {
     _queue.Initialize(game.ChangeTracker);
 }
Exemple #30
0
 public void Initialize(Card owningCard, Game game)
 {
     Game        = game;
     _owningCard = owningCard;
     _counters.Initialize(ChangeTracker, owningCard);
 }