Re: A89: get a number


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

Re: A89: get a number




I got it to work.  Thanks.

--- Olle Hedman <oh@hem.passagen.se> wrote:
> 
> take the address of the first element, add with
> 
> y*elementsize*ywith+x*elementsize  
> 
> and you get the address of the element you want.
> 
> in your example elementsize is 2 (a word)  and ywith
> is 8
> remember to count the first row as row 0
> 
> y*2*8+x*2
> 
> //Olle
> 
> Ben Rodgers wrote:
> > 
> > I have a quick question. How would I get a value
> from
> > something like this
> > 
> > map:
> > ;           |
> > ;           V
> >  dc.w 1,2,3,4,5,6,4,2
> >  dc.w 3,2,4,2,4,1,2,3  <i want that number
> >  dc.w 2,4,2,4,1,2,3,2
> > 
> > 
> > where I want to get the fourth number in the
> second
> > row.  Thanks.
> > ===
> > Visit my website, Some Assembly Required, at
> > http://meltingpot.fortunecity.com/gilford/908
> > 
> >
>
_________________________________________________________
> > Do You Yahoo!?
> > Get your free @yahoo.com address at
> http://mail.yahoo.com
> 
> 

===
Visit my website, Some Assembly Required, at 
http://meltingpot.fortunecity.com/gilford/908 


_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com