Hello Guest

Author Topic: Graphic Question w/ TileMaps & Texture Atlas  (Read 3558 times)

Thyran

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 12
    • View Profile
Graphic Question w/ TileMaps & Texture Atlas
« on: September 09, 2014, 02:16:56 am »
Hey, I had a few questions regarding some "best practices" using the 2D Toolkit. I did a lot of research/experimentation to answer most of my questions, but I had a few that I couldn't get an answer to that I'm hoping I could get some clarification on :)

I've created a lot of simple games in the past that haven't required too much concern over CPU & GPU usage, but I'm taking on a bigger project now that I know I'll have to watch how I design it. I'm designing an simple RPG which will feature the player having characters of several different jobs (e.g. White Mage, Ninja, Assassin, Thief), each with their own set of sprites (idle, walking, attacking, casting, etc). My questions...

1) When setting up the Sprite Collections, should I made one collection per job type to include all the sprites? Like a White Mage collection, Ninja Collection, etc? Or should I try to combine them?

2) When designing a game for the iPhone/iPad, for each Sprite Collection for each job type, should I use the Platform Support to create a 1X and 2X texture atlas?

3) Is there a general rule of thumb for texture atlas max size for iPhone and iPad?

4) I created a TileMap following the tutorial on the 2D Tooklit site. The TileMap uses 3 layers and is using 9 Draw Calls. All the tiles are from the same texture atlas. Is 9 Draw Calls a typical amount? If that's high, are there things I can do to reduce that?

5) Should I be using the Sprite Collection "Platform Support" tool on all Sprite Collections used for things like Tile Maps, heroes, enemies, spells, etc? For every time I use that Platform Support tool, I would need to import into the project 2 or 3 sets of all the sprites at the different resolutions, correct?

6) Based on the project I described, are there any other best practices or rules of thumb I should be following when utilizing the 2D Toolkit to optimize the game's performance?

Thank you so much in advance for answering my questions! Am definitely loving this toolkit :)


unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Graphic Question w/ TileMaps & Texture Atlas
« Reply #1 on: September 09, 2014, 10:50:26 am »
1. Combine them if you can, otherwise you don't really have any choice :)
2. That could be a good idea - definitely a good idea if you can make your game work with that.
3. iPad mini is the black sheep - 2048 is the max texture size. With iPhones, iPhone4 = 2048, everything else is 4096 AFAIK.
4. Thats expected, and not an issue with modern games. You can't do anything about it, as its drawing a fair bit of stuff.
5. Yes.
6. No not really - the usual things apply, try to keep draw calls down and deterministic. These things aren't as much of an issue as they were back in the iPhone 3G days.