How to correctly switch between different types of sprites in a scene?

What is the correct way to create and switch sprites? There are always uncleared items when switching.

When you dispose a sprite, it is removed from the array, so using an ascending loop to remove all the sprites won’t work as expected. You can do it like this instead:

1 Like

I totally forgot about this :sweat_smile: