This is just a demo to show a way to manually handle layers. This is useful if you only want the top most sprite to detect if the mouse is touching it. Press Spacebar to swap the layers. The trick here is that each sprite has a LayerNumber variable. The code on the stage is constantly checking to see what the highest layer number is that is touching the mouse. Then, each sprite can check if they are the highest layer number before responding to mouse clicks or other input.