Skip to content

Commit

Permalink
suppose to be 1 heart not half a heart
Browse files Browse the repository at this point in the history
  • Loading branch information
xNatsuri committed Apr 27, 2024
1 parent a06630a commit fda83ef
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion server/player/player.go
Original file line number Diff line number Diff line change
Expand Up @@ -584,6 +584,7 @@ func (p *Player) Hurt(dmg float64, src world.DamageSource) (float64, bool) {
damageLeft -= a
} else {
p.SetAbsorption(a - damageLeft)

damageLeft = 0
}
}
Expand Down Expand Up @@ -639,7 +640,7 @@ func (p *Player) Hurt(dmg float64, src world.DamageSource) (float64, bool) {

// applyTotemEffects is an unexported function that is used to handle totem effects.
func (p *Player) applyTotemEffects() {
p.addHealth(1 - p.Health())
p.addHealth(2 - p.Health())

for _, e := range p.Effects() {
p.RemoveEffect(e.Type())
Expand Down

0 comments on commit fda83ef

Please sign in to comment.