Fixed bfurself position, added healhbar_colors support
This commit is contained in:
parent
cb6a0c5261
commit
fe107bacdc
@ -147,8 +147,8 @@
|
||||
"no_antialiasing": false,
|
||||
"image": "sprites/characters/YourselfBF",
|
||||
"position": [
|
||||
400,
|
||||
380
|
||||
600,
|
||||
500
|
||||
],
|
||||
"healthicon": "bf",
|
||||
"flip_x": false,
|
||||
|
@ -67,7 +67,8 @@ function _G.Character(name)
|
||||
beats = parsed.beats or 4,
|
||||
animation = "idle",
|
||||
icon = parsed.healthicon,
|
||||
starterFrame = parsed.starter_frame
|
||||
starterFrame = parsed.starter_frame,
|
||||
colors = parsed.healthbar_colors
|
||||
}, CharacterClass)
|
||||
|
||||
for index, alias in next, parsed.animations do
|
||||
|
@ -735,15 +735,18 @@ local function state(songName, songDifficulty, show)
|
||||
|
||||
-- HEALTH BAR
|
||||
if playing and ui.health then
|
||||
love.graphics.setColor(255,0,0)
|
||||
love.graphics.setColor(characters.dad and characters.dad.colors[1]/255 or 0,
|
||||
characters.dad and characters.dad.colors[2]/255 or 1,
|
||||
characters.dad and characters.dad.colors[1]/255 or 0
|
||||
)
|
||||
love.graphics.rectangle("fill", 560, settings.Downscroll and 30 or 1020, 800, 30)
|
||||
love.graphics.setColor(0,255,0)
|
||||
love.graphics.setColor(characters.bf.colors[1]/255,characters.bf.colors[2]/255,characters.bf.colors[3]/255)
|
||||
love.graphics.rectangle("fill", 1360 - health * 400, settings.Downscroll and 30 or 1020, health * 400, 30)
|
||||
|
||||
love.graphics.setColor(0,0,0)
|
||||
love.graphics.rectangle("line", 560, settings.Downscroll and 30 or 1050, 800, 30)
|
||||
|
||||
love.graphics.setColor(255,255,255)
|
||||
love.graphics.setColor(1,1,1)
|
||||
|
||||
if ui.healthIcons then
|
||||
love.graphics.draw(icons.bf.image, health > .2 and icons.bf.alive or icons.bf.dead, 1510 - health * 400, settings.Downscroll and 0 or 930, 0, -1, 1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user