Upon key release?

Blitz3D Forums/Blitz3D Beginners Area/Upon key release?

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.

Well there's a way to detect if a key has been released for an instant.
While Not KeyDown(1)
    If KeyDown(29)
           ;Stuff goes here.
           CtrlPress = True
   else
         If CtrlPress = True
                ;Ctrl has been Released!
                ;Stuff goes here.
                CtrlPress = False ;Now turn off the trigger
         Endif
   Endif
Wend