How do I display an image for a longer time?
Posted: Sun Mar 23, 2014 3:56 am
Hello,
I want to display an image for every state change that takes place. For instance when the player does something right, I might want to display 'Good Job!' on the screen. Currently this is what I have and it works, but the 'Good Job!' image just lasts for a second. I know this is something to do with the update callback but can somebody please tell me how to make the image appear for a little longer time on the screen?
Thanks!
I want to display an image for every state change that takes place. For instance when the player does something right, I might want to display 'Good Job!' on the screen. Currently this is what I have and it works, but the 'Good Job!' image just lasts for a second. I know this is something to do with the update callback but can somebody please tell me how to make the image appear for a little longer time on the screen?
Thanks!
Code: Select all
function love.draw()
if (correct) then
love.graphics.setColor(255,255,255,255)
love.graphics.draw( image, goodjob_x, goodjob_y)
correct = false
end
end