Merge branch 'master' of ssh://cryps.gg:40022/~/cryps
This commit is contained in:
+6
-5
@@ -553,7 +553,7 @@ impl Skill {
|
||||
Skill::Attack => 100, // 1.0 to pass tests
|
||||
Skill::Blast => 130, // BB
|
||||
Skill::Chaos => 50, // BR
|
||||
Skill::Heal => 100, //GG 1.0 to pass tests
|
||||
Skill::Heal => 120, //GG 1.0 to pass tests
|
||||
Skill::Slay => 70, // RG
|
||||
Skill::Strike => 110, //RR
|
||||
Skill::StrikeII => 130,
|
||||
@@ -1315,13 +1315,14 @@ mod tests {
|
||||
y.red_life.force(64);
|
||||
y.red_life.reduce(64);
|
||||
x.red_damage.force(256 + 64);
|
||||
|
||||
let damage: u64 = x.red_damage().pct(Skill::Attack.multiplier()); // 320 * 1.0
|
||||
let healing: u64 = x.green_damage().pct(Skill::Heal.multiplier()); // 256 * 1.2
|
||||
invert(&mut y.clone(), &mut y, vec![], Skill::Invert);
|
||||
assert!(y.affected(Effect::Invert));
|
||||
|
||||
// heal should deal green damage
|
||||
heal(&mut x, &mut y, vec![], Skill::Heal);
|
||||
assert!(y.green_life() == 768);
|
||||
assert!(y.green_life() == (1024 - healing));
|
||||
|
||||
// attack should heal and recharge red shield
|
||||
let mut results = attack(&mut x, &mut y, vec![], Skill::Attack);
|
||||
@@ -1333,12 +1334,12 @@ mod tests {
|
||||
};
|
||||
|
||||
match results.remove(0).event {
|
||||
Event::Healing { skill: _, overhealing: _, amount } => assert_eq!(amount, 256),
|
||||
Event::Healing { skill: _, overhealing: _, amount } => assert_eq!(amount, healing),
|
||||
_ => panic!("not healing from inversion"),
|
||||
};
|
||||
|
||||
match results.remove(0).event {
|
||||
Event::Recharge { skill: _, red, blue: _ } => assert_eq!(red, 64),
|
||||
Event::Recharge { skill: _, red, blue: _ } => assert_eq!(red, (damage - healing)),
|
||||
_ => panic!("not recharge from inversion"),
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user