How do I add repeating bonus?

Just started using Construct 2? Post your questions here

Post » Mon Oct 19, 2015 9:32 pm

Hi everyone,

I cannot figure this out, no doubt you guys will nail it in seconds and make me feel dumb. hehe, I have tried using search but had no luck.

What I want to do is give the player an extra life every 1000 points.

Now I have an event set up that adds 1 to the lives variable when the points hit 1000 and displays a message on screen but what about at 2,3,4,5,6,7,8000++?

Surely there is an easy way to do this?
B
6
S
1
Posts: 73
Reputation: 556

Post » Mon Oct 19, 2015 10:47 pm

try this one.. BonusLives.capx
B
67
S
24
G
7
Posts: 1,518
Reputation: 11,072

Post » Mon Oct 19, 2015 10:57 pm

That's excellent and I would have never thought of that.

Thank you!
B
6
S
1
Posts: 73
Reputation: 556

Post » Mon Oct 19, 2015 11:44 pm

Might not be the most efficient method, but simply having a variable like 'ExtraLivesGiven' and it checks if score is >='ExtraLivesGiven'+1000. If so, add a life and increase 'ExtraLivesGiven' by 1000.
B
52
S
15
G
4
Posts: 191
Reputation: 5,612

Post » Tue May 10, 2016 1:27 pm

Hello korbaach, I have the same problem here but your .capx file is not available. Can you upload it again, please? Thanks!

korbaach wrote:try this one.. BonusLives.capx
B
6
S
1
Posts: 7
Reputation: 430

Post » Tue May 10, 2016 4:10 pm

try again..just click on link BonusLives.capx
and on the ↓Download button

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

Post » Tue May 10, 2016 4:40 pm

For some reason I can't access the file. When I click the link it displays a message saying that the file is confidential. I'll try it later from another network. Thanks.
B
6
S
1
Posts: 7
Reputation: 430

Post » Tue May 10, 2016 5:13 pm

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

Post » Tue May 10, 2016 6:05 pm

Now worked! Thank you very much! Awesome solution, it will help me a lot!
B
6
S
1
Posts: 7
Reputation: 430


Return to Beginner's Questions

Who is online

Users browsing this forum: No registered users and 0 guests