Texture mod fix

This commit is contained in:
Jordan Leppert 2022-02-14 16:05:10 +00:00
parent 8273f25207
commit 3bb1119017
2 changed files with 6 additions and 4 deletions

View file

@ -55,10 +55,11 @@ end
--------------- ---------------
local function indicate_damage(self) local function indicate_damage(self)
self.object:set_texture_mod("^[colorize:#FF000040") local texture_mod = self.object:get_texture_mod()
self.object:set_texture_mod(texture_mod .. "^[colorize:#FF000040")
core.after(0.2, function() core.after(0.2, function()
if creatura.is_alive(self) then if creatura.is_alive(self) then
self.object:set_texture_mod("") self.object:set_texture_mod(texture_mod)
end end
end) end)
end end

View file

@ -203,10 +203,11 @@ local function index_box_border(self)
end end
local function indicate_damage(self) local function indicate_damage(self)
self.object:set_texture_mod("^[colorize:#FF000040") local texture_mod = self.object:get_texture_mod()
self.object:set_texture_mod(texture_mod .. "^[colorize:#FF000040")
core.after(0.2, function() core.after(0.2, function()
if creatura.is_alive(self) then if creatura.is_alive(self) then
self.object:set_texture_mod("") self.object:set_texture_mod(texture_mod)
end end
end) end)
end end