I realise this is kind of a "how long is a piece of string" question, but what's a good upper limit to have for the number of sprites in a layout?
As a bit of background on this, I'm working on a tile-based mining game. At first I was generating every tile sprite individually, which meant I was starting every layout with around 7,500 16x16 sprites from the get-go. I've since switched to using the TileMap object and the framerate gain has been phenomenal, but it's got me thinking about more ways to improve efficiency.
For instance, I have a black "darkness" layer above my main layer, and I was generating a Destinationout "lightwindow" sprite every time the player mines a tile, so that only the area that's been mined out is illuminated. These lightwindow sprites mount up after a while and start impacting framerate, so I started using Rojohound's very excellent Canvas plugin, pasting the lightwindow to the canvas and destroying it on creation. This works nicely, but a one problem is that pasting to canvas causes a very slight stutter, so the compromise I'm considering is to let the lightwindow sprites mount up until they start having an effect on framerate, then pasting & destroying them all at once - this way the stutter only occurs occasionally.
Anyhoo, with this in mind, how many sprites is too many? I realise all systems are different and games will always run less well on less capable machines, but are there any good rules of thumb for this?