diff --git a/mods/ENTITIES/mcl_burning/api.lua b/mods/ENTITIES/mcl_burning/api.lua index 8093d45f9..3fcc7778f 100644 --- a/mods/ENTITIES/mcl_burning/api.lua +++ b/mods/ENTITIES/mcl_burning/api.lua @@ -132,6 +132,7 @@ function mcl_burning.set_on_fire(obj, burn_time) mcl_burning.update_hud(obj) end + --[[ -- FIXME: does this code make sense? It removes attached fire luaentities from -- another object that happen to be at the same position. local fire_luaentity = fire_entity:get_luaentity() @@ -142,6 +143,7 @@ function mcl_burning.set_on_fire(obj, burn_time) break end end + ]]-- end function mcl_burning.extinguish(obj) diff --git a/mods/ENTITIES/mcl_burning/init.lua b/mods/ENTITIES/mcl_burning/init.lua index 62bf3f69a..5ffc804a1 100644 --- a/mods/ENTITIES/mcl_burning/init.lua +++ b/mods/ENTITIES/mcl_burning/init.lua @@ -98,8 +98,7 @@ minetest.register_entity("mcl_burning:fire", { glow = -1, backface_culling = false, }, - animation_frame = 0, - animation_timer = 0, + _mcl_animation_timer = 0, on_activate = function(self) self.object:set_sprite({x = 0, y = 0}, animation_frames, 1.0 / animation_frames) end, @@ -115,9 +114,9 @@ minetest.register_entity("mcl_burning:fire", { return end if parent:is_player() then - self.animation_timer = self.animation_timer + dtime - if self.animation_timer >= 0.1 then - self.animation_timer = 0 + self._mcl_animation_timer = self._mcl_animation_timer + dtime + if self._mcl_animation_timer >= 0.1 then + self._mcl_animation_timer = 0 mcl_burning.update_hud(parent) end end