This commit is contained in:
Mashy 2020-01-09 12:11:11 +10:00
parent 4bb622cc4e
commit 1bc871c66e
2 changed files with 3 additions and 3 deletions

View File

@ -455,7 +455,7 @@ impl Construct {
});
}
pub fn skill_set_cd(&mut self, skill: Skill, cd: Cooldown) -> &mut Construct {
pub fn skill_set_cd(&mut self, skill: Skill) -> &mut Construct {
// println!("{:?} {:?} skill cooldown set", self.name, skill);
// tests force resolve some skills
@ -466,7 +466,7 @@ impl Construct {
// self.skills.insert(i, ConstructSkill::new(skill));
//}
if let Some(sk) = self.skills.iter_mut().find(|s| s.skill == skill) {
sk.set_cooldown(cd);
sk.set_cooldown(skill.base_cd());
}
self

View File

@ -601,7 +601,7 @@ impl Game {
Event::Damage { construct, colour: _, amount: _, mitigation: _, display: _ } =>
self.construct_by_id(construct).unwrap().damage_trigger_casts(&cast, &event),
Event::Cast { construct, skill, player: _, target: _, direction: _ } => {
self.construct_by_id(construct).unwrap().skill_set_cd(skill, skill.base_cd());
self.construct_by_id(construct).unwrap().skill_set_cd(skill);
vec![]
}
Event::Ko { construct } =>