3

I'm just getting things going in my game and I'm using CCTMXLayer for my tiled background. Everything is going fine when my map is 30x30 tiles, but my world is about 500x500 tiles. I would just use a map that size, but it lags terribly during animation. Any ideas as to handle a really large, tiled map without having lag?

InkGolem
  • 2,662
  • 1
  • 15
  • 22
  • +1. I am now using my own map that has a CCBigImage in the background as the terrain (so that it can be created from just a huge image, and have more dynamic look and feel). But I only have round 60x60 tiles so I dont have to mush lag problem with it. I would really like to use gigantic maps as well and started a project on git for this but i never got to finish it as we didnt come to need it in our game. – bobmoff Mar 19 '13 at 21:39
  • I've been trying to think of similar work arounds and I might just use Cocos2d for their CCTMXParser and then use a CGTiledLayer to do the actual drawing. – InkGolem Mar 19 '13 at 22:29

1 Answers1

0

Being biased here: check out Koboldtouch, specifically what features I added to make tilemaps more useful. Among them no limits on map size, tilesets, layers - as much as can fit in memory.

The only alternative is HKTMXTiledMap. I never actually used it, the forum thread is full of (unresolved?) issues.

The CCTMXTiledMap is not only slow, you can only create 128x128 tiles tilemap with a single layer and all tiles set to non-empty. 500x500 is only possible if you leave enough empty tiles so you never go above 16,384 tiles on the map. Unlikely. Restrictive.

CodeSmile
  • 64,284
  • 20
  • 132
  • 217