Posted: 20th Jul 2003 22:56
I am trying to encode a 2d fighting game like mugen
I need help with other things as well but for now that will do

by the way I am using DB pro so please could you code with that if possible
Posted: 20th Jul 2003 23:35
Uhm, this is the wrong board for questions like this. This is for posting snippets only, not asking for snippets. The newbie or DBPro boards would be more suitable.
But anyway, this should work:

+ Code Snippet
`Setup program environment
sync on: sync rate 0
set text opaque

`1 timer unit is 1/1000 of a secone, so 30000 is 30 seconds
`Change this depending on how long you want everything to last
endTime=timer()+30000

do
`Calculate the time that's left
timeLeft=(endTime-timer())/1000

`If there's no time left then end
if timeLeft<1 then end

`Erase previous text on screen
text 0,0,"         "
text 0,0,"Time= "+ str$(timeLeft)
sync
loop


Cheers,
Kentaree