Thank you! I'm happy to make everything a sprite. But I'm curious, are there cases where you'd mix sprites and non-sprites? Or is it basically always inadvisable to do "raw" calls to drawText() etc, because they don't play well with the sprite system?
Thanks!
-Justin
The sprite system can be a real time and performance saver. Once you use it you have to go all in for the reasons you've noticed. This is simply to ensure everything you do will benefit from the optimisations in the sprite system. So, sure, you can mix them but you have to use one sprite as the drawing canvas. But "raw" draw calls to the screen buffer are for without the sprite system.
Also, there are instances where you might not want to use the sprite system at all because of the overhead of processing. For example, it's generally quicker to manage particles manually and draw them manually rather than use sprites to manage them. You can simply have more of them by having your own light weight object rather than a sprite. Of course, if you want to have such particles alongside sprites then you're back to drawing them into an image that you're using as a sprite or background. (this is the approach we use for particles in Sparrow Solitaire).
In comparison:
Ball und Panzer Golf I don't use the sprite system at all.
in some puzzle games I use one sprite as my drawing canvas, to get benefits of partial screen refresh (only redrawing rows of pixels when they change)
Mole Hole I use minimal sprites so I can set and forget certain screen elements.
Adding a bit to what Matt said: If you do have a lot of small sprites moving around it might be more efficient to skip its dirty rect handling and redraw the entire screen every frame with sprite.setAlwaysRedraw().
Also, what's going on when you mix sprites and normal drawing functions is the drawing functions mark those parts of the screen as dirty, then the next time you call sprite.update() it clears them to the background color and redraws the sprites that overlap them. That means anything that you draw manually before sprite.update() will be erased but drawing after the sprite.update() call won't be erased until the next playdate.update() cycle. Most of the time it's easier to just do that drawing in a sprite, as Matt suggested.