set cd
This commit is contained in:
parent
4bb622cc4e
commit
1bc871c66e
@ -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
|
||||
|
||||
@ -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 } =>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user