Timed pop-up targets; Code to do them?

BlitzPlus Forums/BlitzPlus Programming/Timed pop-up targets; Code to do them?

gerald(Posted 2011) [#1]
Hi,

I am making a blitz basic 2D shooter and I would lilke to have my targets pop up for about 2 seconds. I cannot get a loop to work. Part of the problems is that when my game hits the waitmouse() command it stays waiting for the mouse. This stops a timer loop (I think). Any help on this?

Gerald


gerald(Posted 2011) [#2]
Hi,

I figured out how to get the timer value, declare it and combined with a goto back to a while loop start and get it to control time of object. I couldn't use the wait mouse but another goto in a logical control loop gave me the same pop!

thanks.


Matty(Posted 2011) [#3]
Play around with something like this....

if abs(millisecs()-timetopopup)>2000 then 
	timetoppopup=millisecs()
	popupflag=1-popupflag
endif 

if popupflag then
	drawimage myimage,x,y,frame
endif 



gerald(Posted 2011) [#4]
Wow,

Just like Winston Churchill said: Two people seperated by the same language!

thanks,
Gerald