Exemple #1
0
        /// <summary>
        /// Starts the defense.
        /// </summary>
        /// <param name="Attacker">The attacker.</param>
        internal void DefenseStateStarted(Player Attacker)
        {
            this.VisitorPlayer = Attacker;

            foreach (GameObject.GameObject GameObject in this.Player.Home.GameObjectManager.GameObjects[0])
            {
                HitpointComponent HitpointComponent = GameObject.HitpointComponent;

                if (HitpointComponent != null)
                {
                    HitpointComponent.SetHitpoints(HitpointComponent.MaxHitpoints);
                }
            }

            // TODO Simule The Battle.

            this.GameMode.EndDefendState();
        }
Exemple #2
0
 public void UpdateUnitHitpoint(HitpointComponent hp)
 {
     HpBar.UpdateHp(hp.Value);
 }