Ejemplo n.º 1
0
 public override void DoMagic(Magician magician, int strength = 0)
 {
     if (magician.State != Character.CharacterState.Dead)
     {
         magician.ChangeParalyzed();
     }
 }
Ejemplo n.º 2
0
 public override void DoMagic(Magician magician, int strength = 0)
 {
     if (magician.State == Character.CharacterState.Poisoned)
     {
         magician.ChangePoison();
     }
 }
Ejemplo n.º 3
0
 public override void DoMagic(Magician magician, int strength = 0)
 {
     base.DoMagic(magician);
     if (can_use && magician.MP >= mp && magician.State == Character.CharacterState.Paralyzed)
     {
         magician.MP -= mp;
         magician.ChangeParalyzed();
     }
 }
Ejemplo n.º 4
0
 public override void DoMagic(Magician magician, int strength = 0)
 {
     base.DoMagic(magician);
     if (can_use && magician.MP - mp >= 0)
     {
         magician.MP -= mp;
         Debug.Log("Hero mp: " + magician.MP);
         GameObject current_fireball = GameObject.Instantiate(fireball_, hero_.transform.position - new Vector3(0, 0.3f), Quaternion.identity);
         GameObject.Destroy(current_fireball, 5);
     }
 }
Ejemplo n.º 5
0
        public override void DoMagic(Magician magician, int strength = 0)
        {
            base.DoMagic(magician);
            int time = strength / mp;

            if (can_use && magician.State != Character.CharacterState.Dead)
            {
                magician.MP -= time * mp;
                magician.Invulnerable_timer = time;
            }
        }
Ejemplo n.º 6
0
        public override void DoMagic(Magician magician, int strength = 0)
        {
            if (strength > power)
            {
                strength = power;
            }
            power -= strength;

            GameObject current_fireball = GameObject.Instantiate(fireball_, hero_.transform.position - new Vector3(0, 0.3f), Quaternion.identity);

            GameObject.Destroy(current_fireball, 5);
        }
Ejemplo n.º 7
0
 public override void DoMagic(Magician magician, int strength = 0)
 {
     base.DoMagic(magician);
     if (can_use && magician.State != Character.CharacterState.Dead)
     {
         if (magician.MP < strength)
         {
             strength = magician.MP;
         }
         magician.MP -= strength;
         magician.HP += strength * 2;
     }
 }
Ejemplo n.º 8
0
        public override void DoMagic(Magician magician, int strength = 0)
        {
            if (strength > power)
            {
                strength = power;
            }
            power -= strength;

            if (magician.State != Character.CharacterState.Poisoned)
            {
                magician.ChangePoison();
                magician.SetPoison(strength);
            }
        }
Ejemplo n.º 9
0
 public virtual void DoMagic(Magician magician, int strength = 0)
 {
     can_use = true;
     if (voice)
     {
         if (!magician.Voice)
         {
             can_use = false;
         }
     }
     if (move)
     {
         if (!magician.Move)
         {
             can_use = false;
         }
     }
 }
Ejemplo n.º 10
0
 public override void DoMagic(Magician magician, int strength = 0)
 {
     base.DoMagic(magician);
     if (can_use && magician.MP - mp >= 0)
     {
         magician.MP -= mp;
         GameObject current_shock;
         if (hero_.transform.rotation == Quaternion.Euler(0, 0, 0))
         {
             current_shock = GameObject.Instantiate(shock_, hero_.transform.position + new Vector3(3.2f, -0.4f), Quaternion.identity);
         }
         else
         {
             current_shock = GameObject.Instantiate(shock_, hero_.transform.position + new Vector3(-3.2f, -0.4f), Quaternion.identity);
         }
         GameObject.Destroy(current_shock, 1);
     }
 }
Ejemplo n.º 11
0
 public override void DoMagic(Magician magician, int strength = 0)
 {
     magician.MP += power;
 }
Ejemplo n.º 12
0
 public virtual void DoMagic(Magician magician, int strength = 0)
 {
 }