Re: A86: simple code I can't figure out


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

Re: A86: simple code I can't figure out




In a message dated 7/7/99 7:59:51 PM Eastern Daylight Time, 
IVlusicman@aol.com writes:

> Okay...thanks everyone. I learned a lot. There's still a problem that I 
have 
>  with the _getkey equate though. Some tutorial somewhere (Dux's I think) 
told 
> 
>  me that I could type something like this, and it would work:
>  loop:
>   call _getkey
>   cp K_EXIT
>   jr z,exit
>   cp K_ENTER
>   jr z,begin
>   jr loop
>  
>  ...According to what I know (or think I know) about ASM, this would work 
in 
>  order to halt the program until it gets some input. I get it to loop 
alright,
>  
>  but it won't accept any input. Why? 

K_EXIT and K_ENTER are aliased for _getky, not _getkey.  you can either 
change _getkey to _getky, or change K_EXIT to kExit and K_ENTER to kEnter.