When performing image blending, HTML5 cannot do it dynamically in the same way an executable could be performed. Therefore GameMaker Studio 2 has to temporarily save a blended copy of the image and load it in. This function sets how many blended copies of the given sprite can be cached before old ones are overwritten. Default is 4. This is applied to one single given subimage of the sprite.
sprite_set_cache_size_ext(ind, index, max);
|ind||The index of the sprite to change the cache size of.|
|index||The subimage of ind to change the cache size of.|
|max||The maximum number of cached copies of the sprite that can be stored.|
sprite_set_cache_size_ext(sprite0, 0, 2);
This will set the sprite cache of the first subimage of sprite0 to 2 copies.