Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Force 4.0 Reference - __last_scancode last key scan code http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 __last_scancode     Last key scan code
------------------------------------------------------------------------------
 Declaration
   io.hdr

 Syntax
   uint __last_scancode

 Default
   0 (no key pressed).

 Description
   The __last_scancode system variable contains the scan code of the
   last keypress. It is useful for recognizing special keys like F12, gray +,
   etc..

 Example
   #define EXAMPLE_IO
   #include example.hdr

   proc Test_last_scancode
   vardef
      uint uKey
   enddef
   ? "Press keys, finish with Escape"
   ?
   ? "   __last_key __last_scancode"
   ? "============================="
   do while .t.
      uKey := getkey()
      if uKey == K_ESC
         exit
      endif
      ? __last_key, __last_scancode
   enddo
   endproc

   proc main
   Test_last_scancode()
   endproc

See Also: __last_key

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson