Skip to content

Commit

Permalink
replace color value equations with float numbers
Browse files Browse the repository at this point in the history
  • Loading branch information
s-ol committed Nov 5, 2018
1 parent 5053cc0 commit 72f3482
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion examples/011_animation.lua
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ end

function love.load()
-- Set a lovely pink background color.
love.graphics.setBackgroundColor(246*(1/255), 198*(1/255), 222*(1/255))
love.graphics.setBackgroundColor(0.96, 0.77, 0.87)

-- Load the source of the animation.
img = newImagePO2("assets/anim-boogie.png")
Expand Down
10 changes: 5 additions & 5 deletions list.lua
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ function List:new(x, y, w, h)
o.bar = { size = 20, pos = 0, maxpos = 0, width = 15, lock = nil}

o.colors = {}
o.colors.normal = {bg = {48*(1/255), 156*(1/255), 225*(1/255)}, fg = {197*(1/255), 232*(1/255), 255*(1/255)}}
o.colors.hover = {bg = {72*(1/255), 131*(1/255), 168*(1/255)}, fg = {255*(1/255), 255*(1/255), 255*(1/255)}}
o.windowcolor = {48*(1/255), 156*(1/255), 225*(1/255)}
o.bordercolor = {72*(1/255), 131*(1/255), 168*(1/255)}
o.colors.normal = {bg = {0.19, 0.61, 0.88}, fg = {0.77, 0.91, 1}}
o.colors.hover = {bg = {0.28, 0.51, 0.66}, fg = {1, 1, 1}}
o.windowcolor = {0.19, 0.61, 0.88}
o.bordercolor = {0.28, 0.51, 0.66}
return o
end

Expand Down Expand Up @@ -214,4 +214,4 @@ function List:draw()
end


return List
return List
2 changes: 1 addition & 1 deletion main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ function exf.update(dt)
end

function exf.draw()
love.graphics.setBackgroundColor(54*(1/255), 172*(1/255), 248*(1/255))
love.graphics.setBackgroundColor(0.21, 0.67, 0.97)

love.graphics.setColor(1, 1, 1)
love.graphics.setFont(exf.bigfont)
Expand Down

0 comments on commit 72f3482

Please sign in to comment.