WaitKey_or_Mouse()

BlitzMax Forums/BlitzMax Beginners Area/WaitKey_or_Mouse()

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Graphics 640,480

Repeat
	quit:Int = 0
	If MouseHit(1) Then quit = 1001
	If MouseHit(2) Then quit = 1002
        If Not quit
        	quit = GetChar()
        EndIf
	Delay 1	
Until quit <> 0

Print quit