A89: Re: BoulderDash PutSprite Routine
[Prev][Next][Index][Thread]
A89: Re: BoulderDash PutSprite Routine
If I'm not mistaken, all you have to do is change a few .w's to .b's but I
wouldn't do it, because I don't know what I'm doing! (And you might end up
with a few address errors, but I'm not sure...) Sorry I can't help you. =(
-Miles Raymond EML: m_rayman@bigfoot.com
ICQ: 13217756 IRC: Killer2 AIM: KilIer2 (kilier2)
http://www.bigfoot.com/~m_rayman/
----- Original Message -----
From: <ti_calc_guy@email.com>
To: <assembly-89@lists.ticalc.org>
Sent: Wednesday, June 23, 1999 12:12 PM
Subject: A89: BoulderDash PutSprite Routine
> Can someone explain this putsprite routine, and how to make it be an 8x8
routine rather than 16x16? It is from BoulderDash, a _great_ game for the
ti89, so I know it works as it is below. If someone could convert it to
display 8x8 sprites, I would really appreciate it. It seems much simpler
than the routine I saw on the ACZ site.
>
> ; --------------------------------
> ;
> ; Puts a 16x16 sprite (grayscale)
> ;
> ; IN: a0 - Pointer to sprite
> ; d0 - x coord
> ; d1 - y coord
> ;
> ; OUT: -
> ;
> ; --------------------------------
>
> PutSprite:
> movem.l d0-d2/a0-a2,-(a7)
> lsl.w #1,d0
> lsl.w #5,d1
> move.l d1,d2
> lsl.w #4,d2
> sub.w d1,d2
> add.w d0,d2
> lea LCD_MEM,a1
> move.l plane0,a2
> adda.w d2,a1
> adda.l d2,a2
> moveq #3,d0
> PS_NewRow:
> move.w (a0)+,(a1)
> move.w (a0)+,(a2)
> move.w (a0)+,30(a1)
> move.w (a0)+,30(a2)
> move.w (a0)+,60(a1)
> move.w (a0)+,60(a2)
> move.w (a0)+,90(a1)
> move.w (a0)+,90(a2)
> lea 120(a1),a1
> lea 120(a2),a2
> dbra d0,PS_NewRow
> movem.l (a7)+,d0-d2/a0-a2
> rts
>
> -----------------------------------------------
> FREE! The World's Best Email Address @email.com
> Reserve your name now at http://www.email.com
Follow-Ups:
References: