How do I check the active layout [Solved]

Get help using Construct 2

Post » Wed Sep 23, 2015 12:48 pm

I have a few layouts that have a shared event sheet and I want to be able to check what the currently active layout is so that 1 event can act differently based on the layout.

I currently have a variable I'm changing in accordance to the layout swaps. It works but I doubt it will easy to keep track of when the number of layouts grow.

something like:

spacebar pressed
>> current layout == "this layout" >> do this thing
>> current layout == "that layout" >> do that thing


Thanks for your time :)
Last edited by UrsaFrank on Wed Sep 23, 2015 9:39 pm, edited 1 time in total.
B
8
S
1
Posts: 10
Reputation: 420

Post » Wed Sep 23, 2015 1:16 pm

How different are this thing and that thing?
Is the thing different on every layout?
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Wed Sep 23, 2015 1:58 pm

It's jumping from layout to layout.

I'll try to explain it more specifically:

Each layout is its own room (birds eye view) in 2 by 2 grid. When the player walks outside the layout the player will be sent do another room.

If they are in the bottom left room layout and they walk off the top of the layout, the go to the top left room layout, but if they are in the bottom right room layout and they walk of the top of the top of the layout then, they will end up at the top right room layout.

Like i said I currently have a variable keeping track of the layout the player is currently in but it would make things a lot easier down the line if I could just check the current layout via the shared event sheet for the event.
B
8
S
1
Posts: 10
Reputation: 420

Post » Wed Sep 23, 2015 2:25 pm

Image
B
67
S
24
G
7
Posts: 1,518
Reputation: 11,072

Post » Wed Sep 23, 2015 2:49 pm

That is fantastic! Thanks a load :D
B
8
S
1
Posts: 10
Reputation: 420

Post » Wed Sep 23, 2015 2:55 pm

...er... Is there anyway I can mark this as solved? This is my first topic.
B
8
S
1
Posts: 10
Reputation: 420

Post » Wed Sep 23, 2015 5:55 pm

@DonpatchXD There's no need to explicitly mark as solved. However, if you really want to, you can always prefix something like "[SOLVED]" to the beginning of the topic title by editing the first post.
Moderator
B
113
S
41
G
20
Posts: 1,586
Reputation: 19,126

Post » Wed Sep 23, 2015 9:39 pm

That's great thanks :D
B
8
S
1
Posts: 10
Reputation: 420


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 22 guests