Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- FUNCky - <b>name:</b> <b>scancode() - get scancode of last keypress</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
  Name:     scancode() - get scancode of last keypress
  Usage:    <integer> = scancode()
  Params:   none
  Returns:  integer equal to the scancode of the last key pressed.
            if scancode() is zero, then check xscancode() for the
            extended scan code. If they are both zero, then no key
            was pressed.

 ---------------------------------- Example ---------------------------------

            * The IBM PC, PS/2 Tech. Ref. manuals contain the listings
            * for all the extended scan codes. If a key that does not
            * have an extended scan code is pressed, then scancode()
            * will return the ascii value of that key. Remember to do
            * the scancode() and xscancode() check exactly as you
            * would with lastkey():

                    tempkey = inkey(0)
                    if (scancode() = 0)
                            xscan = xscancode()
                    endif

See Also: xscancode()

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