currency: Use proper change colors
parent
e72e1a1852
commit
62527b727b
|
@ -26,9 +26,18 @@ function node:render()
|
|||
love.graphics.printf("BTCPLN", 0, 180, love.graphics.getWidth()/2, 'right')
|
||||
love.graphics.printf("TRYIDR", 0, 350, love.graphics.getWidth()/2, 'right')
|
||||
love.graphics.setFont(textFont)
|
||||
|
||||
love.graphics.setColor( 0, 255, 0 )
|
||||
if self.state.changes[1] then
|
||||
love.graphics.setColor( 0, 255, 0 )
|
||||
else
|
||||
love.graphics.setColor( 255, 0, 0 )
|
||||
end
|
||||
love.graphics.printf(self.state.values[1], love.graphics.getWidth()/2 + 2*pad, 180, love.graphics.getWidth()/2 - 2*pad, 'left')
|
||||
|
||||
if self.state.changes[2] then
|
||||
love.graphics.setColor( 0, 255, 0 )
|
||||
else
|
||||
love.graphics.setColor( 255, 0, 0 )
|
||||
end
|
||||
love.graphics.printf(self.state.values[2], love.graphics.getWidth()/2 + 2*pad, 350, love.graphics.getWidth()/2 - 2*pad, 'left')
|
||||
else
|
||||
love.graphics.setColor( 255, 255, 255, 80 )
|
||||
|
|
Loading…
Reference in New Issue