How do I Create this type of randomness

Get help using Construct 2

Post » Tue Jun 28, 2016 10:23 am

here is an example:
CAPX

EDIT:
you could even spawn by probability:
Code: Select all
CallFunction("SpawnPipe", "random(4)")

If Parameter > 0: Spawn
Else: Skip

This would be a chance of 3:1
B
11
S
4
G
5
Posts: 73
Reputation: 3,431

Post » Tue Jun 28, 2016 10:50 am

realMantis wrote:here is an example:
CAPX

EDIT:
you could even spawn by probability:
Code: Select all
CallFunction("SpawnPipe", "random(4)")

If Parameter > 0: Spawn
Else: Skip

This would be a chance of 3:1



Gap between pipes are big
if possible gap should be single pipe width
Image
B
63
S
39
G
42
Posts: 626
Reputation: 30,470

Post » Tue Jun 28, 2016 10:53 am

Than just add the same spawn action to the skip condition. Than it will only create a one gap

EDIT:
sry this doesn't work, i take a look at it
B
11
S
4
G
5
Posts: 73
Reputation: 3,431

Post » Tue Jun 28, 2016 10:57 am

No no no
this is remove gap between them and randomness is removed
Image
B
63
S
39
G
42
Posts: 626
Reputation: 30,470

Post » Tue Jun 28, 2016 11:00 am

give me a second, i post an updated capx soon
B
11
S
4
G
5
Posts: 73
Reputation: 3,431

Post » Tue Jun 28, 2016 11:01 am

ok then make a player too
to test that player can go a long away
Image
B
63
S
39
G
42
Posts: 626
Reputation: 30,470

Post » Tue Jun 28, 2016 11:16 am

I updated the CAPX. Now it skips only ones per time.

luckyrawatlucky wrote:ok then make a player too
to test that player can go a long away

Sry, but i can't make your game for you. Implementing a player should be no task ;)
B
11
S
4
G
5
Posts: 73
Reputation: 3,431

Post » Tue Jun 28, 2016 11:24 am

Thanks for help
I'll test it
Image
B
63
S
39
G
42
Posts: 626
Reputation: 30,470

Post » Tue Jun 28, 2016 11:26 am

I updated it again, now it scrolls with the pipes. CAPX
B
11
S
4
G
5
Posts: 73
Reputation: 3,431

Post » Tue Jun 28, 2016 11:40 am

Oh Thanks
Image
B
63
S
39
G
42
Posts: 626
Reputation: 30,470

PreviousNext

Return to How do I....?

Who is online

Users browsing this forum: Linetaru and 7 guests