示例#1
0
 private void Swipe()
 {
     if (GetDistanceFromTarget() <= meleeRange)
     {
         target.ReceiveDamage(100);
         //target.Knockback (Vector3.left, 2f);
         target.transform.Translate(-swipeKnockbackValue, 0.0f, 0.0f);
     }
 }
示例#2
0
 void Update()
 {
     if (isDamaged == true)
     {
         acidSpitTimer += Time.deltaTime;
         if (acidSpitTimer > acidSpitDuration)
         {
             acidSpitTimer = 0.0f;
             mechaman.ReceiveDamage((int)acidDamage);
         }
     }
 }