Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I am making a game using Cocos2d-x and want to support multiple mobile phone resolutions and sizes.

Right now I have made my game sprite sheets set on a resolution of iPad Retina's resolution of 2048X1536 and then will use Tiled Map editor to design my game levels.

My question is on what basis do I scale my sprite sheets for different resolutions suppose iPhone etc so that my Tiled Map's design does not get effected when used in the game ?

share|improve this question
1  
What do you mean by does not get affected? –  Evgeni Petrov Jun 19 '13 at 11:22
    
In my game, i got a global flag for standard tile size. When I scale my sheets by a global factor to adjust to screen size as you mentioned, I only nee to scale that flag too. It really depends on how you implemented it –  jens Jun 19 '13 at 11:57

1 Answer 1

up vote 1 down vote accepted

It depends on your implementation.

A. You can keep tile size constant (e.g. 64px). This way depending on screen resolution the number of tiles that fit on the screen will change. And of course you will need to take care about retina displays, cos they have very high pixels-per-cm density.

B. You can scale your tiles to preserve constant physical size (e.g. 2cm). For that you need to know how many pixels fit into physical 2cm (look into display dpi setting) and scale accordingly.

C. You can choose a simple approach and always render 10 tiles across irregardless of screen size and pixel density.

Pick the way that suits your game best.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.