limiting platform jump score and text score

Get help using Construct 2

Post » Mon May 13, 2013 7:30 am

how can I limit my character on gaining score to 1x only as it jumps to a sprite that is jump through.

and how to do the text score that increments fast instead of changing automatically. for example, as the player jumps it gets 50 pts. of score then the text from 0 increments fast up to 50 instead of 0 to 50 without inrementing.

thanks in advance.
B
3
Posts: 15
Reputation: 305

Post » Mon May 13, 2013 11:29 am

For your first problem use trigger once condition.

For your second problem.

+on jump
-> golabal variable NewPoints + 50

+ Every X(e.g 0.25) seconds
+ NewPoints > 0
-> Points + 1
-> NewPoints - 1
-> Set Text to Points


Hope this helps, if not I will explain it you more detail
B
15
S
6
G
6
Posts: 512
Reputation: 5,550

Post » Tue May 14, 2013 2:11 am

I tried to put trigger once, but it doesn't seem to work right.
I did this way, or am I doing it wrong?



and what is Every X in conditions?
B
3
Posts: 15
Reputation: 305

Post » Tue May 14, 2013 2:32 am

oh I already got the flow in second problem but I'm not sure what is Points + 1.
B
3
Posts: 15
Reputation: 305

Post » Tue May 14, 2013 9:17 am

You want to simulate the growing of your score so you need variables

score = points in my example (It keeps the actual score, than you add 1 to it every X seconds)

newPoints = a variable to help you let the score growing, it just saves how much you need to add over time to the players score.


For your first problem:
-> Do you try to make achievements ? If yes trigger once is the false condition.
If yes you need a small achievement system, with an array or something else.
If you want I can explain it you a bit more.

Sry for the bad english, need some coffee :DDarklinki2013-05-14 09:22:09
B
15
S
6
G
6
Posts: 512
Reputation: 5,550

Post » Tue May 14, 2013 10:29 am

ok I get the second one. thanks.

on the second, I'm trying to get rid of getting scores repeatedly as it jumps on the same platform.

like 1 platform = 50pts. if it jumps on the same platform again, there will no points acquired.
B
3
Posts: 15
Reputation: 305

Post » Tue May 14, 2013 10:42 am

or if there's some tutorial here that has scoring system like 'doodle jump' would be better.
B
3
Posts: 15
Reputation: 305

Post » Tue May 14, 2013 11:26 am

Totally easy,

1. give the platforms an instance variable, something like "scored"
2. set scored to false in the properties
3. The Event:

+ Player on collide with Platform

++ If Platform instance variable "scored" = false
--> newPoints + 50
--> Set Platform scored = true


This is all, will work totally fine, tried it already.Darklinki2013-05-14 11:27:32
B
15
S
6
G
6
Posts: 512
Reputation: 5,550

Post » Tue May 21, 2013 3:15 am

thanks man! it worked fine..
B
3
Posts: 15
Reputation: 305


Return to How do I....?

Who is online

Users browsing this forum: makkancs and 25 guests