mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-26 12:31:05 +01:00
Exhaust for falling anvil damage
This commit is contained in:
parent
3c72330880
commit
59930fd13c
2 changed files with 4 additions and 0 deletions
|
@ -1,2 +1,3 @@
|
|||
mcl_sounds
|
||||
mcl_core
|
||||
mcl_hunger
|
||||
|
|
|
@ -36,6 +36,9 @@ local on_step_add = function(self, dtime)
|
|||
hp = 0
|
||||
end
|
||||
v:set_hp(hp)
|
||||
if v:is_player() then
|
||||
mcl_hunger.exhaust(v:get_player_name(), mcl_hunger.EXHAUST_DAMAGE)
|
||||
end
|
||||
if hp == 0 then
|
||||
kill = true
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue