Is there a way to randomize layers?

Get help using Construct 2

Post » Tue Dec 27, 2011 10:25 pm

I want to set up a game that uses the same set background, but has multiple layers. At the start of the game, I would like the system to randomly select one of the layers, and disable all the others. Is this possible?
B
6
S
1
G
1
Posts: 52
Reputation: 829

Post » Tue Dec 27, 2011 10:29 pm

Of course (if i understood correctly and for disabled you mean invisible). If you have ex. 4 layers just set then all disabled/invisible on editor or on start of layout. Then also on start of layout put System: Set Layer (random(0, 3)) Visible.Kiyoshi2011-12-27 22:31:16
B
58
S
13
G
10
Posts: 632
Reputation: 12,505

Post » Tue Dec 27, 2011 11:06 pm

Worked like a charm. You rock!! Thanks!
B
6
S
1
G
1
Posts: 52
Reputation: 829


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 15 guests