Scale sprites for every resolution

Hi guys,

I’ve worker on my first game i finally have all thing and try to test on some devices, on high resolution and low devices.

So my question is i know you can scale images on corona (@2x,@4x) based on our device resolution, we just need to have the correct images named.

How you can deal with that with sprites? I’ve create some sprites on the game, i’ve used texturepacker, and my sprite are made with hardcoded resolution let’s say 128x128, that is work fine on my simulator however if i change to a device with high resolution it’s appear too smal if i use a device with low  resolution it’s apper to big. 

The same thing for some images that I use for some obstacles and i use physicseditor to setup the physics parts hardcode for a resolution, how i can scale that for each resolution? 

I’m not able to change width and heigth of sprites.

Thanks 

Hi @masterviana,

Sprites are based on image sheets, so if you include the specifications for a dynamically-selected image sheet, sprites will automatically use the different versions of the sheet which their frames exist upon.

See this guide under “Dynamically-Selected Image Sheets”:

https://docs.coronalabs.com/guide/media/imageSheets/index.html

Brent

Hi @masterviana,

Sprites are based on image sheets, so if you include the specifications for a dynamically-selected image sheet, sprites will automatically use the different versions of the sheet which their frames exist upon.

See this guide under “Dynamically-Selected Image Sheets”:

https://docs.coronalabs.com/guide/media/imageSheets/index.html

Brent