Page 1 of 1

How to make an object jump?

Posted: Mon Dec 31, 2018 2:41 pm
by Ol1vver
Hello,
Is there any possible way to make an object jump?
Example:
There is a crate on the map.
When you activate something, the crate jumps up, like a normal player, while still keeping it's physics (able to move, etc).

Re: How to make an object jump?

Posted: Tue Jan 01, 2019 1:10 am
by ebomb09
'SetLinearVelocity()' function if you can use the Script Editor

Re: How to make an object jump?

Posted: Tue Jan 01, 2019 2:53 pm
by Ol1vver
ebomb09 wrote:
Tue Jan 01, 2019 1:10 am
'SetLinearVelocity()' function if you can use the Script Editor
I don't understand what to type in, though.

I realised.
I had to use "[object].SetLinearVelocity(new Vector2([l/-r],[u/-d]))". (l - left, -r - right, u - up, -d - down)
Thanks!