Exemplo n.º 1
0
 public void OnTriggerExit(Collider collision)
 {
     if (collision.gameObject.tag == "AtkSpd")
     {
         AbstractWeapon.GetWeaponCooldownHolder(this.gameObject).SetCooldownMultiplier(1.0f);
     }
 }
Exemplo n.º 2
0
    // Workaround for unity bug where OnTriggerExit is not called if the object tracking entry
    // or exit is destroyed.
    IEnumerator DestroyObject(GameObject gameObject)
    {
        yield return(new WaitForSeconds(despawnTimer));

        Destroy(gameObject);

        AbstractWeapon.GetWeaponCooldownHolder(this.gameObject).SetCooldownMultiplier(1.0f);
    }
Exemplo n.º 3
0
 public void OnTriggerEnter(Collider collision)
 {
     if (collision.gameObject.tag == "AtkSpd")
     {
         // Change GetFirstWeapon to apply attack speed to all weapons?
         AbstractWeapon.GetWeaponCooldownHolder(this.gameObject).SetCooldownMultiplier(1.0f / attackSpeedMultiplier);
     }
 }