Mobile performance and optimizations tips

0 favourites
From the Asset Store
An addon collection that provides native mobile features for C3 and C2 game application projects.
  • I do have a question concerning getting better mobile optimizations. I have a few different menus in my game where the player can select from one of many sprites. The sprites contained in these menus are normally all set to not visible unless the menu is open. These sprites only appear in groups, and there are never more than 16 on-screen. they are relatively small, and from my testing on older devices, the game menus are playable but are down in the low end of the frame rate spectrum when any one of these menus are opened.

    Here is my question: Is it better to set all the sprites invisible and only set them visible when they need to be on screen, or is it better to create and destroy sprites as they are needed on screen?

    Do hidden or nonvisible sprites still take up processing power? or do they need to be completely destroyed to take up non?

  • haypers This is an old thread and the Construct Team doesn't really like us replying on old topics unless it's really related to the OP.

    Anyway, regarding your question. Yes, setting them off-screen or invisible does improve performance and the canvas doesn't draw them, an exception is by setting the opacity to 0, which still draws on the canvas and does consume resources.

    Create / Destroy actually uses up more performance compared to re-using instances. But fortunately, the c2runtime especially the c3runtime supposedly has a pooling system which reuses instances, that's why bullet-hell games don't have a huge performance impact and are optimized, in the basic form.

    A side-tip, disabling events by Groups, on the CPU-side, can give a huge performance improvement. Especially events that are not triggers (green arrow conditions), such as Every Tick condition events.

    Using functions / trigger events when necessary compared to just using toggle every-tick condition events, can be a huge performance improvement too.

    I hope that enlightened you in the subject.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Thx. Sorry about using this thread. Didn't realize it was so old. Now that I post a new reply, I can see the thousands of warnings that I somehow ignored the first time.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)