Rapid Key Pressing

Blitz3D Forums/Blitz3D Beginners Area/Rapid Key Pressing

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.

Or the er, hard way if you want to keep track of pressed and held keys:

If KeyDown(TAB) ; where TAB is a constant holding
; the scancode for tab
If TAB_Held = 0 ; cumulative variable
Switch_CameraMode() ; Your camera switching stuff
EndIf
TAB_Held = TAB_Held + 1
Else ; reset TAB_Held when tab's not pressed
TAB_Held = 0
Endif