diff options
author | 2024-03-18 04:19:34 +0100 | |
---|---|---|
committer | 2024-03-18 04:19:34 +0100 | |
commit | 937e1ed8d240c1a5b42f5b8cf1104321b9d79c4a (patch) | |
tree | c9cc6f8ec35e3e9b1ba97b5fd42091cf0ab2afb6 /src/shared/champion.rs | |
parent | ab675360c0005718a3c9b8b5e7962af897269c04 (diff) |
fix: fix abilities selecting the right cooldown
Diffstat (limited to 'src/shared/champion.rs')
-rw-r--r-- | src/shared/champion.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/shared/champion.rs b/src/shared/champion.rs index 8de12a5..28d1ff2 100644 --- a/src/shared/champion.rs +++ b/src/shared/champion.rs @@ -40,14 +40,14 @@ impl Stats { } impl Champion { - pub fn to_ability(self, attack_key: AttackKey) -> Ability { + pub fn to_ability(self, ability_slot: AbilitySlot) -> Ability { match self { - Champion::Meele => match attack_key { - AttackKey::Q => Ability::Directional(DirectionalAbility::Spear), + Champion::Meele => match ability_slot { + AbilitySlot::Q => Ability::Directional(DirectionalAbility::Spear), _ => Ability::Targeted(TargetedAbility::MeeleAttack), }, - Champion::Ranged => match attack_key { - AttackKey::Q => Ability::Directional(DirectionalAbility::Spear), + Champion::Ranged => match ability_slot { + AbilitySlot::Q => Ability::Directional(DirectionalAbility::Spear), _ => Ability::Targeted(TargetedAbility::RangedAttack), }, } |