Hi,
I am working on a puzzle game, and I'm having trouble layering the objects so that when one of the pieces is 'picked up' by the mouse, it is drawn to the front until another is placed on top. Now, I understand that the ones drawn last in the program will be the ones visible at the front, but the trouble is I don't know how to achieve this.
At the moment, I have made it so that the one being picked up is drawn to the front, but as soon as the mouse button is released it goes back to its normal depth. This would be fine, but as I create the pieces like this:
01, 02, 03,
04, 05, 06,
07, 08, 09.
... piece number 01 will always be drawn behind 02 etc., which gives the game away as it shows where the piece is meant to be.
I have been looking around for an answer to a similar question for a while, but I haven't found any which match my problem. Any help on how to alter the depth of objects would be greatly appreciated :)
Thanks in advance,
KingD.
P.S. Sorry if I have been a bit vague, please ask if something I've said doesn't make sense :)
1