Gambit37 wrote:^^ Not sure you ever saw the above tutorial request?
I saw it. I haven't gotten around to it, yet, sorry.
Gambit37 wrote:How can I create a sequence of fullscreen renderers that play in sequence, and each one fades frm one to the next after either (a) a period of time and/or (b) a mouse click?
A non-nil return value from any of the functions called by a fullscreen renderer will end it.
There is a helpful click function called
EXIT_ON_CLICK that will handle the mouse clicks, and you can do the timing in an update function, which is called 5 times a second, the same rate as DSB's game timer.
Here is code to display
gfx.full_screen_graphic for 30 seconds, or end it early if the user clicks.
Code: Select all
function my_graphics_timer()
gt_timer = gt_timer + 1
if (gt_timer > 5*30) then
return true
end
end
gt_timer = 0
dsb_fullscreen(gfx.full_screen_graphic, EXIT_ON_CLICK, my_graphics_timer, false, true)