Game Development Community

Simsets with objects vs Tilemap

by kupo · in Torque Game Builder · 02/29/2012 (1:26 pm) · 1 replies

Just a curious question :

I divide my screen space into blocks (ie - 8x6 = 48 blocks). Is it more resource friendly to use a tilemap for this?

Currently I've been using a simset with 48 individual objects in it and refreshing it through calls on the simset.

What are the pros/cons to this as far as speed?

#1
03/11/2012 (3:13 pm)
Kind-of late, but here's an answer:

48 sprites won't tax the system, especially if they aren't animating. A prototype I'm working on has a few hundred sprites, text, and a few particle effects. There's no slowdown (60+ frames a second).

Tilemaps can be limited. They can't rotate (only flip). But they do run EXTREMELY fast. I have another prototype which had several hundred sprites that animated. It taxed the system to the point of unplayability. When I moved it over to a tilemap, the game ran as fast as if it had no sprites.

I find tilemaps to be most useful when the tiles don't need to update often or interact with each other. I find sprites to be best in all other cases. And in the few games where I've needed both, I wrote a custom t2dSceneObject that acted like a tilemap with the additional features that I needed.

Good luck!