[A83] Re: Map question
[Prev][Next][Index][Thread]
[A83] Re: Map question
ld l,a
ld h,0 ;hl=sprite number
add hl,hl ;*2
add hl,hl ;*4
add hl,hl ;*8
ld de,sprites ;pointer to start of sprite table
add hl,de
push hl
pop ix ;ix now equals pointer to our sprite (for ionputsprite)
----------------------------------------------
Original Message
From: ""<Mike3465@aol.com>
Subject: [A83] Map question
Date: Sat, 17 Mar 2001 17:24:23 EST
>
>Ok, i'm making a map program to use for an rpg I'm thinking about, and i
was
>wondering if i could do this:
>
>(normal code, and then some to get the tile num(0-255) into a)
> ld f,0
> sla a
> sla a
> sla a ;same as a=a*8;
> add hl,af ;or should i exchange a to f? I'm not sure, i want to add
the
>offset of ;the tile(a) to the tile data(hl) any help here?
>(normal code to display tile located at hl)
>
>would that work? or do i need to exchange a and f to get the right code?
or
>could i just say " add hl,a" and that work?
>
>Any help would be....helpfull
>
>
>
_____________________________________________
Free email with personality! Over 200 domains!
http://www.MyOwnEmail.com