1
0
mirror of https://codeberg.org/tenplus1/mobs_redo.git synced 2024-09-21 20:20:26 +02:00

fix constant health tag

This commit is contained in:
TenPlus1 2017-05-28 20:57:14 +01:00
parent 608a5178cf
commit f40d260a81

View File

@ -372,6 +372,11 @@ end
-- check if mob is dead or only hurt
local check_for_death = function(self, cause)
-- has health actually changed?
if self.health == self.old_health and self.health > 0 then
return
end
self.old_health = self.health
-- still got some health? play hurt sound