How to optimize Spine character loading with tons of PNG files in Construct 3?

0 favourites
  • 3 posts
From the Asset Store
Excel2JSON
$1.20 USD
60% off
Convert multiple Excel files into JSON files and import them into construct3.
  • We're working on a game that's using this Spine plugin for character animations, and we're facing a performance issue

    Our setup:

    - Each character consists of 3 PNG files of the skin (hat, head, body)

    - We have approximately 200 PNG files total to make skin customization possible.

    - Single atlas and json file

    - The game has 20 players in the layout

    The problem:

    Spine requires all PNG files to be linked to the object, even if they're not being used, this forces Construct to load all the files causing significant performance issues.

    On mobile devices we're seeing a framerate drop to around 20fps

    What we've tried:

    -We've already programmed a dynamic loading for the necessary files using the "Load spine files" event. However it doesn't work because Spine requires all files in the atlas to be linked.

    Has anyone encountered a similar issue? How did you managed to solve it? We're looking for a way to dynamically load ONLY the PNG files associated with the currently active character skin.

    Any suggestion would be greatly appreciated!

  • I probably won't be much of help, but my tip - I would message the developers of the plugin directly. Especially if you donated a few $ to them, they should be willing to help, they must have encountered it. I remember looking into the plugin back then and I remember they specifically addressed the performance issues with phones in some early versions. But maybe it has changed recently. I have published my first iOS game recently (not using this plugin, so that's why I can't be not much of a help) so now I get how much you have to optimize VRAM memory for older mobile devices, which I didn't realize before - so now I'm also very interested how to do multiple skins on animated characters in Construct 3 to work on older phones, so please, if you find a solution, post it here as well for me :) Thanks!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The solution is to export everything into a single atlas PNG (2048x2048 or 4096x4096), avoiding separate PNGs for each skin. Spine automatically resizes the output if the total size of the skin PNGs exceeds the maximum. If the FPS remains low, try adjusting the Spine render rate.

    Thanks to Mikal!

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