Jump to content

A platformer for mobile, but without tilemaps. Any tips? Occlusion culling, etc?


kriket
 Share

Recommended Posts

Posted on phaser forum but thought I might also ask pixi guys as well, since it is a question about rendering.


 


I am thinking of making a platformer game but without tilemaps cos the extra work needed in photoshop to create seamless tilemaps is just not worth it for me, when I can just put sprites in and make a level out of them (especially since the game will only have about 4, short-medium length levels anyway). 


 

Can someone give me tips on how I can optimize such a platformer, made without tilemaps, for mobile?

Or if this indeed is a good way to go about this?

 

I am thinking about things that other engines like Unity, use. Occlusion culling (of off-screen sprites), texture packing/atlases, etc.

 


Optimize for mobile. I havent started yet, but just wanted to know if it's possible to do this without tilemaps (since tilemaps seem the standard for platformers), and get the thing running on mobile. 


 


 


Link to comment
Share on other sites

I am thinking about things that other engines like Unity, use. Occlusion culling (of off-screen sprites), texture packing/atlases, etc.

 

You should do all those things. Phaser has features to help with off-screen sprites culling, you will need to pack assets yourself and use sheets.

 

As for using large images on levels, make sure the textures aren't too big. There are maximum sizes to textures to be used on the GPU: http://webglstats.com (see MAX_TEXTURE_SIZE at the very bottom). For mobile 4096 is a good number to stay under (that is the width x height of your image). If your images are too big you will need to break them up and tile them.

Link to comment
Share on other sites

Thank you so much. Game itself will mostly consist of static sprites (terrain), just one animating sprite (player), at most 10 sprites being tweened on screen and a few effects like in "run pixie run". That's all.

 

I knew phaser had features such as object pooling, etc. Forgot that it also did off-screen culling out of the box. Texture packing and spritesheets wont be an issue as I know how to do that. 

 

So the only thing I need to take into consideration is to not make any single sprite larger than say 4096. But apart from that a platformer with a medium-length level shouldn't run into other technical difficulties, am I right? Especially since off-screen culling means it really shouldn't matter how long the level is and how many assets the game has in total (although preloading assets will take a bit longer). 

 

 

PS - I loved "Run pixie run" and had a lot of things to learn from such a simple game. Can I pls ask whether you used a 2d effects package for that one and what was it? I want to buy it.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...