mirror of
https://github.com/IntQuant/noita_entangled_worlds.git
synced 2025-10-19 07:03:16 +00:00
heal to 15% instead of 10%, give a proper min of 10
This commit is contained in:
parent
05487b881b
commit
92c644531a
1 changed files with 3 additions and 1 deletions
|
@ -154,7 +154,9 @@ function module.on_world_update()
|
|||
if not ctx.my_player.currently_polymorphed and has_hp then
|
||||
if hp_new <= 0 then
|
||||
-- Restore the player back to small amount of hp.
|
||||
util.set_ent_health(ctx.my_player.entity, {max_hp_new / 10, max_hp_new})
|
||||
local new_hp = 3 * max_hp_new / 20
|
||||
local final_hp = math.max(new_hp, math.min(2/5, max_hp_new))
|
||||
util.set_ent_health(ctx.my_player.entity, {final_hp, max_hp_new})
|
||||
player_died()
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue