GreatSprites is in preparation. Join early access for two free tests at launch.
GreatSprites Early access

Docs

Memory and loading

What an element costs on a phone and on desktop, and how to free it.

Loading an element loads every clip in its folder at the size that fits the height you give, and keeps them until you destroy the element. Your export's weight-report.json lists GPU memory per clip on a phone and on desktop, and the totals.

A recommended whole-game budget on a phone is about 32 MB of GPU memory and 15 MB of animation download. In our own games that holds about 25 seconds of animation.

Freeing

coin.destroy();   // removes this copy

Copies of the same element at the same height share one loaded set of pages: fifteen coins cost the memory of one. Destroying a copy keeps the pages for the others; when no copy will be shown again, free them:

gs.release('./sprites/object-1/');

← Living backgroundsSizes →