Advertisement

2D Tile Engine (Several Topics Here)

Started by February 10, 2001 11:32 AM
9 comments, last by LordElectro 23 years, 7 months ago
I am using a similar tile engine for my game. I made it along time ago and when I made it I made some mistakes that I have to pay for now...
here are some tips:

- Don''t use layers! make each tile a linked list and link it other tiles. Using just takes up memory and makes some more advanced thing more hard later on. It is alot harder to do (especially the editor) but it is woth it!

- Don''t have all info in a TILE_INFO struct. Have some little info in the tile array aswell. If you want to save space You could just use bit flags (8 flags = 1 byte). You shoudl save things as visable, walkable, slippery and stuff like that. When the map is loaded the flags are set to standard values that are in the TILE_INFO struct.

- Incoproprate animated tiles at the very beginning! The sooner you do it the more advnced you can make it. Trust me!

- Use RLE sptites (run length encoded sprites). Transperant tiles take less space and are drawn faster! IF you think they are hard to code use a library like allegro (allegro.cc for info on that.)

- Make the mapeditor userfriendly. If not noone will se the engine.

Thats all from me! Good luck with the enigne!




-------
Me Hardguy.
and here is my game...

This topic is closed to new replies.

Advertisement