Re: A86: getkey program


[Prev][Next][Index][Thread]

Re: A86: getkey program




Doesn't _getky do that already? or was I just dreaming that...

Jeff Zimmerman
Minkus2@juno.com

On Thu, 3 Sep 1998 23:08:14 EDT BrncAvFan2@aol.com writes:
>
>In a message dated 9/3/1998 8:01:27 PM Mountain Daylight Time,
>electrum@tfs.net writes:
>
><< Try this (not tested):
> 
> loop:
>  call _getkey
>  or a			; zero?
>  jr z,loop		; wait until a key has been pressed
>  ld hl,$3020		; (X, Y) location of text in HEX
>  ld hl,(_penCol)
>  ld h, 0		; Display3Dnum -----------------------
>  ld l, a
>  call UNPACK_HL
>  add a, 48		; 48 is the start of character '0' (zero)
>  ld c, a		; Save 3rd digit
>  call UNPACK_HL
>  add a, 48
>  ld b, a		; Save 2nd digit
>  call UNPACK_HL	
>  add a, 48		; A =  1st digit
>  call _vputmap		; Display 1st digit
>  ld a, b
>  call _vputmap		; Display 2nd digit
>  ld a, c
>  call _vputmap 		; Display 3rd digit
>  jr loop		; ----------------------------------
>  >>
>
>
>I need a program that will tell me the number for the key. I mean like 
>if I
>push F1, it will display 11, and so forth.  I could do it the long way 
>whereas
>I would have to do a cp k1, etc. but I was wondering if there was a 
>shorter
>way.
>

_____________________________________________________________________
You don't need to buy Internet access to use free Internet e-mail.
Get completely free e-mail from Juno at http://www.juno.com
Or call Juno at (800) 654-JUNO [654-5866]


References: