gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

Graphics > Tilemap problem

#9364 - www-fmsoftware-info - Sun Aug 03, 2003 12:05 am

[Images not permitted - Click here to view it]

Wots going wrong?
I'm using a 512x512 map.
The tileset loads properly into the memory (according to mappy).
But the tiles display incorrectly.

I adapted gbajunkies 512x512 map demo.

Please help.

TIA.
_________________
[Images not permitted - Click here to view it]
www.fmsoftware.info

#9376 - mtg101 - Sun Aug 03, 2003 1:57 am

Ah yes... I saw this a time ago. IIRC it was because my tile bitmap had an odd number of tiles horizontally (I think it was 15x9 tiles (120x72 pixels)). To fix it I had to make the number of horizontal tiles even, in my case 16x9 (128x72 pixels).

NB: I happened to have 16 as my even number for horizontal tiles... it may be that the horizonal amount of tiles must be amultiple of 4 or 8 or 16, rather than just even (and I just got lucky with using 16).
_________________
---
Speaker for the Dead

#9388 - www-fmsoftware-info - Sun Aug 03, 2003 9:56 am

Thanks for your help.

I've solved now.
I've been using a 128x128 tiles bitmap - which wasn't the problem.
The block select mode in 'GBA Map Editor' was causing the problem.

Use block select - gobbly-de-gook
Use normal select - fine

I think I'll need a new mouse with all the clicking I'm gonna be doing!
_________________
[Images not permitted - Click here to view it]
www.fmsoftware.info

#11582 - www-fmsoftware-info - Sat Oct 11, 2003 7:19 pm

I'm having a wierd problem with my tilemap now.

I've looked in lots of the technical documents but can't find the answer.

On Gameboy hardware & MappyVM my game appears like this:

[Images not permitted - Click here to view it]

but it should appear like this:

[Images not permitted - Click here to view it]

I'm using 128x128 tiles.


I hope someone can help.


Chris.
_________________
[Images not permitted - Click here to view it]
www.fmsoftware.info

#11584 - www-fmsoftware-info - Sat Oct 11, 2003 7:46 pm

Here's some more information.

o The background is on BG2
o The numbers on the left (1,2,3,4) flash by changing the BG tile data
o When the numbers are lit the background displays properly


C
_________________
[Images not permitted - Click here to view it]
www.fmsoftware.info

#11585 - tepples - Sat Oct 11, 2003 7:47 pm

You may have inadvertently turned on two maps at once, scrolled to different positions. Try opening VBA's Map Viewer and seeing if your map data is intact.

Or you may have incorrectly computed the offset of map memory.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.

#11588 - www-fmsoftware-info - Sat Oct 11, 2003 9:42 pm

I'ts ok I've fixed it.

With Rotational backgrounds don't call
UpdateBackground(&bg2);
every frame - it causes the above effect.


Chris.
_________________
[Images not permitted - Click here to view it]
www.fmsoftware.info