Re: A83: sprite won't clear completly


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

Re: A83: sprite won't clear completly




Cory Derenburger wrote:
> 
> Hey guys, thanx for your help yesterday with sprite sizes, changing the
> e in the sprite routine worked.  What I am making is a guy that walks
> around the screen.  My problem is that when he is facing a direction and
> you move him in another he turns around and doesn't quite clear himself
> completely and leaves streaks.  How can I fix this?

You must erase the old drawing before you make a new one.  Since you're
using an XOR routine, this is as easy as redrawing the sprite in the old
location as well as the new.

> Also, when he walks of the left side of the screen he pops out at about
> the middle.  How can I set the domain so when he gets to the edge he
> stops?

That should be as simple as a few conditionals.  You can figure this one
out, I hope.

But if you want your sprites to clip at the edges, you'll have to find
another routine, or modify the current one to do this.

-- 
John Kugelman.  kugelman@mnsinc.com

I believe we can change anything.
I believe in my dream.
    - Joe Satriani


References: