Re: A85: Sprite Routines


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

Re: A85: Sprite Routines




At 05:46 PM 4/20/98 -0500, you wrote:
>What sprite routines does everyone use?  Are there any good routines that
>don't have clipping but can also do larger than 8x8?

I use a routine (for the TI-82 but easily ported...designed it myself) that
allows for any size sprite to be displayed (up to the size of the screen).
I think clipping is one of the best features ever made for any sprite
routine, as many games require the use of objects that move off of the edge
of the screen.  SpriteDraw, the routine I use, is one such routine but
clipping is easily disabled (3-4 lines of code disable clipping) and just
displays the image.  It is the FASTEST routine that is available for the 82
and is highly optimized.

I'm sorry to say that it doesn't support masking.  Masking is a new
technique for sprites (for the 82 anyway) that erases a defined section of
the screen (where the sprite will be displayed) and then displays the
sprite.  Masking won't work, however, with scrolling buffers, that my
graphics routines use because all of the screen buffers would have to be
cleared (wherever the sprite was located), which would make masking slow
and useless.  However, masking becomes useful in a single layer environment
because there is no background behind the sprite in another buffer.

If anyone wants the library to attempt to port the routines to the 85, I'd
be glad to send the most recent version to them.  There is a new Collision
routine which has so far been untested.  So, I have no idea if the 82 will
even crash or not using that routine.  Collision will detect a SOLID
collision between two shrunken bounding boxes of any two (they can even be
different sized) sprites.  However, remember it's untested and so it might
have a bug or two in it.


                 Thomas J. Hruska -- thruska@tir.com
Shining Light Productions -- "Meeting the needs of fellow programmers"
         http://www.geocities.com/SiliconValley/Heights/8504
                    http://shinelight.home.ml.org


Follow-Ups: References: