Reseting position of random Objects

Get help using Construct 2

Post » Fri Nov 29, 2013 6:40 pm

I put some Objects on a Layer within an Array at random position
And some more at the bottom that are fix

I want to drag some objects to the one at the bottom

but if i drop an object in an empty space, i want it to return at the place it was before. choosed by the random

Can someone help me on that?
Thank you

My random placement: took from Random Tile map Tutorial

Array set value at (array.curX, array.CurY) to floor(random 0,5))
System Create object Objects on layer 1 at (32 + (array.CurX*64) ,32 + (array.CurY*64))
Objects set animation frame to array.CurValue

Quote megatronx Quote Post ReplyReply Direct Link To This Post Posted: Today at 1:48am

Create Variables ObjectsX and ObjectsY and set them to Objects.X and Objects.Y respectively. Then use those two when moving it back to original position.

Ah! it workd perfectly thank you
Posts: 3
Reputation: 156

Return to How do I....?

Who is online

Users browsing this forum: ChenBr and 4 guests