Use DrawFaded / fadedImage with a tilemap?

Hey folks, I was wondering if anyone knows how (or if) I can pull the image from a sprite with a tilemap (in this case, a level created with LDtk and imported using this tool: https://devforum.play.date/t/importer-for-ldtk-level-editor) so that I can use the fadedImage method to allow the level sprites to fade in and out? The result of myLevelLayerSprite:getImage is nil, but I'm hoping there's some other way to get it—or even to create an image by essentially screenshotting the background, and then fading that. Any help would be appreciated!

You can draw into an image using lockFocus or pushContext and then fade that.

Or your can grab the current screen, and fade that. Use getDisplayImage/getWorkingImage.

1 Like

Thank you! That ended up working.

1 Like