diff options
Diffstat (limited to 'src/shared/cooldown.rs')
-rw-r--r-- | src/shared/cooldown.rs | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/shared/cooldown.rs b/src/shared/cooldown.rs index f27d7fc..2d6b6ae 100644 --- a/src/shared/cooldown.rs +++ b/src/shared/cooldown.rs @@ -5,13 +5,12 @@ use serde::Serialize; use std::default::Default; #[derive(Component, Message, Serialize, Deserialize, Clone, Copy, PartialEq, Debug, Default)] -pub struct Cooldown { - pub a_cooldown: Duration, - pub q_cooldown: Duration, - pub w_cooldown: Duration, - pub e_cooldown: Duration, - pub r_cooldown: Duration, - pub d_cooldown: Duration, - pub f_cooldown: Duration, - pub g_cooldown: Duration, +pub struct Cooldown(pub [Duration; 7]); + +pub struct BaseCooldown(pub [Duration; 7]); + +impl BaseCooldown { + pub fn from_champion(_champion: Champion) -> Self { + BaseCooldown([1., 5., 5., 10., 25., 50., 50.].map(Duration::from_secs_f32)) + } } |