Game Development Community

Tile Map Questions

by Devboy · in Torque X 2D · 10/09/2007 (1:49 pm) · 1 replies

Hi

1. Assuming a scene that would 'fit' a tiling scenario, What is the benefit of using a tile map as opposed to just placing object in the scene yourself?
2. I couldn't get the T2DTileLayer to work from code... anyone care to paste a code example of how to set one up (including assigning tiles)?

Cheers,
DB

#1
10/10/2007 (8:24 am)
1. I haven't run the numbers myself, but it's probably better performance to use a tilelayer instead of a bunch of sprites in a grid. You don't have the overhead of multiple objects. There may also be some other minor benefits. But if using lots of sprites makes more sense to you, and it's not causing problems in your game, then use what makes more sense to you.

2. Check out this thread and see if that helps.