Exemplo n.º 1
0
 public void hurt(popupText damage, Character character = null)
 {
     this.dot (damage, character);
     this.addEnergy(15);
 }
Exemplo n.º 2
0
    public void dot(popupText damage, Character character = null)
    {
        this._hurt = damage.value;
        this.buffEffect("hurt");
        this.debuffEffect("hurt");

        damage.value = this._hurt;
        this.damagePopupQueue.Enqueue (damage);	//傷害文字佇列

        //回合結束時,一次性扣掉血量
        this.shield -= this._hurt;
        if (this.shield < 0) {
            this.hp += this.shield;
            this.shield = 0;
        }

        this.setHpBar ();

        if(this.hp <= 0 && !this.dead){
            this.die();
        }
    }