level select question

Get help using Construct 2

Post » Tue Sep 10, 2013 10:32 pm

Hi all,

watching the great tutorial on level select :
https://www.scirra.com/tutorials/311/level-page

i have the level select screen functioning like in the tutorial but i dont know how to apply the following:

I want to load a new layout (level) on touching/clicking a specific levelsprite.

So far the screen goes to winscreen and then looping to the level screen and so on = as the tutorial. I tried to compare the level variables of the levelsprites on touch/click and for example when the level sprite has value 0, load layout/level1. But so far its ignoring this input :/.

B
8
S
4
G
1
Posts: 191
Reputation: 1,873

Post » Tue Sep 10, 2013 10:38 pm

Do you have a CAPX you can share? Would be easier to help find out what's wrong.
B
101
S
32
G
11
Posts: 1,552
Reputation: 21,667

Post » Tue Sep 10, 2013 11:33 pm

[QUOTE=ArcadEd] Do you have a CAPX you can share? Would be easier to help find out what's wrong.[/QUOTE]

Hi ArcadEd,

https://www.dropbox.com/s/4kskr0lu6u2zvtr/example_level_select.zip

there are 2 files.

thanks again!
B
8
S
4
G
1
Posts: 191
Reputation: 1,873

Post » Wed Sep 11, 2013 7:17 am

Seems to work correctly and it sets currentlevel correctly so not sure what the problem is.
B
46
S
16
G
74
Posts: 2,089
Reputation: 44,187

Post » Wed Sep 11, 2013 8:04 am

The problem is , i dont know how to load a specific level for example on touch, load layout level. But this didnt worked so far :/
B
8
S
4
G
1
Posts: 191
Reputation: 1,873

Post » Wed Sep 11, 2013 5:58 pm

You don't have any layouts apart from the level select screen and the win screen....
You need to create the layouts first. Then use GoToLayout actions.
B
46
S
16
G
74
Posts: 2,089
Reputation: 44,187

Post » Wed Sep 11, 2013 10:58 pm

i fixed it :) just a path expression was missing so it can find the layouts one after another "LVL"&levelsprite.level
B
8
S
4
G
1
Posts: 191
Reputation: 1,873


Return to How do I....?

Who is online

Users browsing this forum: Yahoo [Bot], yiuyiu6666 and 12 guests