public CharactersAttack(IGame game, IPlayer attackingPlayer, IEnemyInPlay enemy, IEnumerable <IAttackingInPlay> attackers) : base(game) { this.AttackingPlayer = attackingPlayer; this.Enemy = enemy; this.attackers = new ObservableCollection <IAttackingInPlay>(attackers); }
public EnemyAttack(IGame game, IPlayer defendingPlayer, IEnemyInPlay enemy, IEnumerable <IDefendingInPlay> defenders) : base(game) { this.DefendingPlayer = defendingPlayer; this.Enemy = enemy; this.defenders = new ObservableCollection <IDefendingInPlay>(defenders); this.attack = enemy.Card.PrintedAttack; }
public EnemyAttack(IGame game, IPlayer defendingPlayer, IEnemyInPlay enemy, IEnumerable<IDefendingInPlay> defenders) : base(game) { this.DefendingPlayer = defendingPlayer; this.Enemy = enemy; this.defenders = new ObservableCollection<IDefendingInPlay>(defenders); this.attack = enemy.Card.PrintedAttack; }
public void RemoveEnemy(IEnemyInPlay enemy) { if (enemy == null) throw new ArgumentNullException("enemy"); if (!enemies.Contains(enemy)) return; enemies.Remove(enemy); }
public EnemyDefeated(IGame game, IEnemyInPlay enemy, IEnumerable<IAttackingInPlay> attackers) : base(game) { if (enemy == null) throw new ArgumentNullException("enemy"); if (attackers == null) throw new ArgumentNullException("attackers"); this.Enemy = enemy; this.Attackers = attackers; }
public void RemoveEnemy(IEnemyInPlay enemy) { if (enemy == null) { throw new ArgumentNullException("enemy"); } if (!enemies.Contains(enemy)) { return; } enemies.Remove(enemy); }
public void AddEngagedEnemy(IEnemyInPlay enemy) { if (enemy == null) { throw new ArgumentNullException("enemy"); } if (engagedEnemies.Contains(enemy)) { return; } engagedEnemies.Add(enemy); }
public EnemyDefeated(IGame game, IEnemyInPlay enemy, IEnumerable <IAttackingInPlay> attackers) : base(game) { if (enemy == null) { throw new ArgumentNullException("enemy"); } if (attackers == null) { throw new ArgumentNullException("attackers"); } this.Enemy = enemy; this.Attackers = attackers; }
public override void Trigger(IGame game, IEffectHandle handle) { IEnemyInPlay enemy = null; foreach (var player in game.Players) { enemy = player.EngagedEnemies.Where(x => x.Card.Id == source.Id).FirstOrDefault(); if (enemy != null) { break; } } if (enemy == null) { handle.Cancel(GetCancelledString()); return; } game.AddEffect(new AttackModifier(game.CurrentPhase.Code, source, enemy, TimeScope.Round, 1)); handle.Resolve(GetCompletedStatus()); }
private static string GetDescription(IEnemyInPlay enemy) { return string.Format("{0} has been defeated", enemy.Title); }
public EnemyDefeatedEffect(IGame game, IEnemyInPlay enemy, IEnumerable<IAttackingInPlay> attackers) : base("Enemy Defeated", GetDescription(enemy), game) { this.enemy = enemy; this.attackers = attackers; }
private static string GetDescription(IEnemyInPlay enemy) { return(string.Format("{0} has been defeated", enemy.Title)); }
public EngagamentCheckEffect(IGame game, IPlayer player, IEnemyInPlay enemy) : base("Engagement Check", string.Format("{0} must check to see if '{1}' engages them", player.Name, enemy.Title), game) { this.player = player; this.enemy = enemy; }
public void AddEngagedEnemy(IEnemyInPlay enemy) { if (enemy == null) throw new ArgumentNullException("enemy"); if (engagedEnemies.Contains(enemy)) return; engagedEnemies.Add(enemy); }
public EnemyDefeatedEffect(IGame game, IEnemyInPlay enemy, IEnumerable <IAttackingInPlay> attackers) : base("Enemy Defeated", GetDescription(enemy), game) { this.enemy = enemy; this.attackers = attackers; }
public EnemyEngaged(IGame game, IPlayer defendingPlayer, IEnemyInPlay enemy) : base(game) { this.DefendingPlayer = defendingPlayer; this.Enemy = enemy; }
private void DealFourDamageToEnemyInPlay(IGame game, IEffectHandle handle, IPlayer player, IEnemyInPlay enemy) { enemy.Damage += 4; handle.Resolve(string.Format("{0} chose to have '{1}' deal 4 damage to '{2}'", player.Name, CardSource.Title, enemy.Title)); }