How do I create a high score for each level

Get help using Construct 2

Post » Sun Aug 03, 2014 5:42 pm

Hello, i´m making a game, has got three levels and i need a high score for each level. I made the first level high score but when i´m going to make the high score of the next level it stays in 0 points and isn't save the new scores.
Image
B
41
S
11
G
2
Posts: 73
Reputation: 3,012

Post » Sun Aug 03, 2014 5:48 pm

i don't get you, do you want to save the individual scores for each level separately and make it available in the next level or what? Also, do your levels run in different layouts.
Your choices are to store in array, webstorage or a simple global variable.
Better still explain your question very well.
B
15
S
4
Posts: 138
Reputation: 2,003

Post » Sun Aug 03, 2014 5:50 pm

Yes, i need individual scores for each level separately
Image
B
41
S
11
G
2
Posts: 73
Reputation: 3,012

Post » Sun Aug 03, 2014 8:57 pm

then create then in separate variables i believe
B
15
S
4
Posts: 138
Reputation: 2,003

Post » Mon Aug 04, 2014 4:10 pm

Dasat wrote:then create then in separate variables i believe

I try with different global variables in different layers and only work in the first level.
Image
B
41
S
11
G
2
Posts: 73
Reputation: 3,012

Post » Mon Aug 04, 2014 4:22 pm

share a capx
B
15
S
4
Posts: 138
Reputation: 2,003

Post » Mon Aug 04, 2014 5:36 pm

Dasat wrote:share a capx


Here is the capx: https://www.dropbox.com/s/i5m8t30h3o5uc ... Score.capx
Image
B
41
S
11
G
2
Posts: 73
Reputation: 3,012

Post » Mon Aug 04, 2014 5:49 pm

You don't need to duplicate events sheets for every level/layout. You should use a single events sheet and just track the level stuff separately. Just keep a global variable with the level number and append this to the HighScore tag when using WebStorage.

The immediate problem is you didn't change the 'Add 1 to CutObjects" action. (Should have been CutObjects2).
ImageImageImage
B
72
S
22
G
290
Posts: 3,885
Reputation: 159,511

Post » Mon Aug 04, 2014 6:06 pm

"The immediate problem is you didn't change the 'Add 1 to CutObjects" action. (Should have been CutObjects2). "

Yes, was this, thanks so much.
Image
B
41
S
11
G
2
Posts: 73
Reputation: 3,012

Post » Fri Aug 29, 2014 4:24 pm

blackhornet wrote:You don't need to duplicate events sheets for every level/layout. You should use a single events sheet and just track the level stuff separately. Just keep a global variable with the level number and append this to the HighScore tag when using WebStorage.

The immediate problem is you didn't change the 'Add 1 to CutObjects" action. (Should have been CutObjects2).



Hi friend,could you please write an example of using webstorage with tag of the level number?????

Many many thanks!!!!!
B
7
S
1
Posts: 3
Reputation: 447

Next

Return to How do I....?

Who is online

Users browsing this forum: blackhornet, IronHeart and 56 guests