A89: sprite


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

A89: sprite



I've written a program to make sure i know how to use sprites.  The file is attached.  It
basically moves a sprite around the screen using the four arrow keys, and recalls the background
that was there before.  
I put in if statements to keep it from running off the edge of the screen, and all of them work
fine except for one.  When it gets 4 pixels from the left edge of the screen, it stops (early). 
It can keep moving around after that, but as long as it has hit that barrier whenever you hit esc
to quit, it gets an illegal instruction error.  
I noticed that the case for the left move was last in the switch, so I tried switching it with the
second to last (the up move).  For some reason, this causes everything to work normally except for
the left move: this now moves it up and to the left.  
What is going on???
jeff

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/

sprites.c


Follow-Ups: