# How do I create an infinity or an eight sign trajectory?

Get help using Construct 2

### » Thu Mar 19, 2015 7:35 pm

I need to create an infinity or an eight sign trajectory in Construct2 without extra plugins.
I have found the formulas but I can't port them because I don't know Math enough

First formula
x = cos(t);
y = sin(2*t) / 2;

and looks like this:

Lemniscate of Gerono animation

Second formula:

scale = 2 / (3 - cos(2*t));
x = scale * cos(t);
y = scale * sin(2*t) / 2;

It looks like this:

Lemniscate of Bernoulli animation
B
124
S
51
G
24
Posts: 401
Reputation: 22,617

### » Thu Mar 19, 2015 8:02 pm

Visual Novel 'Engine' in 100 Events
if you ever have to choose between buying Construct 2 on scirra.com or on Steam, read this: Review
B
22
S
9
G
1
Posts: 788
Reputation: 3,788

### » Thu Mar 19, 2015 9:07 pm

mindfaQ wrote:there you go:
https://copy.com/peH6Upm8jirpoI31

You are genius man. Thanks a lot!
B
124
S
51
G
24
Posts: 401
Reputation: 22,617

### » Fri Mar 20, 2015 7:13 pm

@mindfaQ

Is there a way to have two blocks running in the same trajectory in different direction?

thanks,
B
124
S
51
G
24
Posts: 401
Reputation: 22,617

### » Sat Mar 21, 2015 7:50 am

different direction: either use a minus in front of every "cycle" you see in the sin/cos formulas OR instead of adding dt to the cycle, substract dt from it.
Visual Novel 'Engine' in 100 Events
if you ever have to choose between buying Construct 2 on scirra.com or on Steam, read this: Review
B
22
S
9
G
1
Posts: 788
Reputation: 3,788

### » Sat Mar 21, 2015 9:01 pm

Thank you very much!
B
124
S
51
G
24
Posts: 401
Reputation: 22,617