Fixed explosion color of sceptre M2.

This commit is contained in:
Sam 2020-08-30 12:08:26 -05:00
parent 387f2cb60c
commit 36762be2a7

View File

@ -390,7 +390,7 @@ impl Scene {
pos,
power,
reagent,
..
percent_damage,
} => self.event_lights.push(EventLight {
light: Light::new(
*pos,
@ -400,7 +400,13 @@ impl Scene {
Some(Reagent::Purple) => Rgb::new(0.7, 0.0, 1.0),
Some(Reagent::Red) => Rgb::new(1.0, 0.0, 0.0),
Some(Reagent::Yellow) => Rgb::new(1.0, 1.0, 0.0),
None => Rgb::new(1.0, 0.5, 0.0),
None => {
if *percent_damage < 0.5 {
Rgb::new(0.0, 1.0, 0.0)
} else {
Rgb::new(1.0, 0.5, 0.0)
}
},
},
*power
* match reagent {