public PCCombatant(PlayerCharacter owner, BattleArena Battle) { this.name = owner.name; this.attributes = owner.attributes; this.Battle = Battle; this.attack = new basicAttack(this, 1000); }
public Timeline(BattleArena battle) { this.battle = battle; timeline = new List <PlayerTurn>(); fill(); sort(); battle.printSpeed(timeline); }
/// <summary> /// Start a new Combat /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void StartButton_Click(object sender, EventArgs e) { combatants = new List <PlayerCharacter>(); ConsoleWindow.Items.Clear(); combatants.Add(new PlayerCharacter("You", Battle)); //combatants.Add(new PlayerObjectModel("Ally", ref Battle)); combatants.Add(new PlayerCharacter("They", Battle)); //combatants.Add(new PlayerObjectModel("They2", ref Battle)); Battle = new BattleArena(this);// ref combatants, this); }
public EnemyAITurn(BattleArena battle, ICombatant owner) { this.phases = new List <Phase>(); this.battle = battle; this.owner = owner; //timeUntilTurn = this.owner.calc_time_cost(500); //currentPhase = 0; //timeOut = false; ActionPhase = new Phase(400); ActionPhase.phaseTime.timer.Tick += new EventHandler(attack); phases.Add(ActionPhase); }
public PlayerTurn(BattleArena battle, ICombatant owner) { this.phases = new List <Phase>(); this.battle = battle; this.owner = owner; timeUntilTurn = this.owner.calc_time_cost(500); current_phase = 0; timeOut = false; freePhase = new Phase(200, new EventHandler(next_phase)); ActionPhase = new Phase(1000, new EventHandler(next_phase)); phases.Add(freePhase); phases.Add(ActionPhase); }
public PlayerCharacter(string name, BattleArena Battle) { this.name = name; this.attributes = new Attributes(8, 14); this.combatant = new PCCombatant(this, Battle); }