I have this:



map0 dd 1,7,7,7,0,7,7,7,7,2
dd 8,0,0,0,0,0,0,0,0,9
dd 8,0,0,0,0,0,0,0,0,9
dd 8,0,0,0,0,0,0,0,0,9
dd 8,0,0,0,0,0,0,0,0,9
dd 8,0,0,0,0,0,0,0,0,9
dd 8,0,0,0,0,0,0,0,0,9
dd 8,0,0,0,0,0,0,0,0,9
dd 8,0,0,0,0,0,0,0,0,9
dd 4,6,6,6,6,6,6,6,6,3
.data?
mapptr dd ?


when I access it directly, it works fine:
m2m eg, map0

when I try to use the pointer method, it fails me - probably really simple too..I've tried:
m2m mapptr,
m2m mapptr, OFFSET map0
m2m mapptr, DWORD PTR
etc..

m2m eg,mapptr

Thanks.
Posted on 2004-05-28 17:20:51 by drarem
So, you have this map0 block of data and you have mapptr.

mov mapptr, offset map0

Will give store the address.


later if you want to get data from map0 using mapptr i think you need to

mov eax, mapptr
mov eq, DWORD PTR

I am not sure if there is another way....I just use registers and it works :alright:
Posted on 2004-05-28 18:13:17 by Milos
that was it, thanks.
Posted on 2004-05-28 19:23:34 by drarem