Help with the levelselect

Get help using Construct 2

Post » Wed Nov 02, 2016 1:09 pm

I have a problem: https://www.dropbox.com/s/kfw9o7jrqr24r ... elect.capx

1º If just level 1 and I give below the stars and give to win and leaves the levelselect the stars obtained is preserved

2º But if instead of giving the win, give it to the next level at all levels and go to levelselect none is saved

You have to leave the levelselect to be saved?

PS: I want three different sprites because I have images for each level so I think three different levelsbutton.
B
11
S
5
G
1
Posts: 410
Reputation: 2,802

Post » Wed Nov 02, 2016 5:43 pm

nobody knows?
B
11
S
5
G
1
Posts: 410
Reputation: 2,802

Post » Wed Nov 02, 2016 6:42 pm

Can you better explain the issue? It seems to be working fine and I tested it for ages. What are the exact button press steps that are not saving for you?
B
46
S
16
G
79
Posts: 2,170
Reputation: 46,857

Post » Wed Nov 02, 2016 7:52 pm

I say step by step
1º You enter Level 1
2º You take the stars as you want
3º You give arrow next level
4º You repeat the same with the previous levels
5º Move to select level in the last level and not the stars got saved :(

Thank you very much for trying to help ;)
B
11
S
5
G
1
Posts: 410
Reputation: 2,802

Post » Wed Nov 02, 2016 9:11 pm

The last level being 3 right? Seems fine. If you select WIN then it saves. If you select FINISH to go back then it does not save, but this never works on any level because you only have the save to array logic under the WIN. I assume this is intentional?
B
46
S
16
G
79
Posts: 2,170
Reputation: 46,857

Post » Thu Nov 03, 2016 9:49 am

How to change the array to level 3 to keep me out into levelselect previous stars?
The problem is that if you entered the level and go to levelselect if I save it, but if you use next to level 3 and out is not saved ...
I'm pretty novice, you can fix?
I'm sorry for my English :(

1->2->3 go to the level select = you keep the above stars collected
-> = next
B
11
S
5
G
1
Posts: 410
Reputation: 2,802

Post » Thu Nov 03, 2016 10:45 am

When you click "Finish Level" (object named "complete") you do not save stuff in the array. So the current's level start aren't saved.
Otherwise, apparently, you have the same code for the "win" and "next" objects.

In the end, you should try to factor everything to only use a single event sheet instead of one event sheet per level.

Use the function object to reuse the similar code, and when you click buttons, call this code.
Use "Go to layout by name" using your CurrentLevel variable to go to the appropriate layout. ("level" & currentLevel)
New to Construct ? Where to start

Image Image

Image Image

Please attach a capx to any help request or bug report !
Moderator
B
292
S
115
G
96
Posts: 7,295
Reputation: 70,795

Post » Thu Nov 03, 2016 11:00 am

I swear I try and I hate to ask you if you fix the capx please.
Perhaps this level select to serve others :P
Sorry for my English, I am Spanish.
B
11
S
5
G
1
Posts: 410
Reputation: 2,802

Post » Thu Nov 03, 2016 7:52 pm

:cry:
B
11
S
5
G
1
Posts: 410
Reputation: 2,802

Post » Thu Nov 03, 2016 8:13 pm

ImageImage
B
109
S
49
G
23
Posts: 783
Reputation: 22,636

Next

Return to How do I....?

Who is online

Users browsing this forum: brunopalermo, JackTYGA, worm1 and 27 guests