Skip to content

Commit

Permalink
fix healing player under sacrifice below 0hp not ending game
Browse files Browse the repository at this point in the history
  • Loading branch information
serprex committed Apr 6, 2024
1 parent 8c9572f commit 53e9a9b
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/rs/src/game.rs
Expand Up @@ -1873,20 +1873,20 @@ impl Game {
dmgdata.dmg = dmg;
dmgdata.amt = capdmg;
self.proc_data(Event::Dmg, id, &mut dmgdata);
if dmg > 0 {
if realdmg < 0 {
return dmg
} else {
if (!dontdie || kind == Kind::Player) && self.truehp(id) <= 0 {
self.die(id);
} else if self.get(id, Flag::voodoo) {
let foe = self.get_foe(self.get_owner(id));
self.dmg(foe, dmg);
self.dmg(foe, capdmg);
}
if sosa {
-capdmg
} else {
capdmg
}
}
if realdmg < 0 {
dmg
} else if sosa {
-capdmg
} else {
capdmg
}
}

Expand Down

0 comments on commit 53e9a9b

Please sign in to comment.