this idiot forgot to commit an entire month's worth of code
This commit is contained in:
parent
c67146ea1a
commit
a3321d361c
51 changed files with 3644 additions and 84 deletions
18
Assets/Scripts/Abilities/Upgrades/KillCooldown.cs
Normal file
18
Assets/Scripts/Abilities/Upgrades/KillCooldown.cs
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
using UnityEngine;
|
||||
|
||||
public class KillCooldown : AbilityUpgrade
|
||||
{
|
||||
public float damageIncrease;
|
||||
public float cooldownChange;
|
||||
[SerializeField] private KillCooldownRuntimeObject runtimeObject;
|
||||
|
||||
protected override void UpgradeEffects(PlayerAbility abilityToUpgrade, float optionalInput)
|
||||
{
|
||||
base.UpgradeEffects(abilityToUpgrade, optionalInput);
|
||||
abilityToUpgrade.canCooldown = false;
|
||||
abilityToUpgrade.cooldown = abilityToUpgrade.baseCooldown * cooldownChange;
|
||||
KillCooldownRuntimeObject newRuntimeObject = Instantiate(runtimeObject, abilityToUpgrade.transform);
|
||||
newRuntimeObject.ability = abilityToUpgrade;
|
||||
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue