hp-bar-the-dumb-way #22

Merged
PeaAshMeter merged 7 commits from hp-bar-the-dumb-way into main 2025-12-07 20:35:58 +03:00
Showing only changes of commit 73ba99734c - Show all commits

View File

@ -39,14 +39,6 @@ function skillButton:draw()
return
end
if self.selected then
love.graphics.setColor(0.3, 1, 0.3)
elseif self.hovered then
love.graphics.setColor(0.7, 1, 0.7)
else
love.graphics.setColor(1, 1, 1)
end
local quad = icons:pickQuad(self.icon)
love.graphics.push()
love.graphics.translate(self.bounds.x, self.bounds.y)
@ -55,6 +47,15 @@ function skillButton:draw()
love.graphics.pop()
self:drawBorder("inner")
if self.selected then
love.graphics.setColor(0.3, 1, 0.3, 0.5)
love.graphics.rectangle("fill", self.bounds.x, self.bounds.y, self.bounds.width, self.bounds.height)
elseif self.hovered then
love.graphics.setColor(0.7, 1, 0.7, 0.5)
love.graphics.rectangle("fill", self.bounds.x, self.bounds.y, self.bounds.width, self.bounds.height)
end
love.graphics.setColor(1, 1, 1)
end
--------------------------------------------------------------------------------