How do I create a revolute joint at runtime

Just started using Construct 2? Post your questions here

Post » Tue Apr 29, 2014 7:27 pm

Hi,

I want to construct a simple car at run-time.
At first all parts (2 wheels and a chassis at the moment) are laying on the floor, away from each other.
All parts have Physics behavior and all are movable (except the floor).

Then, lets say on touch, I want to assemble the car and let it drive away.
Now, in order to create the revolution joints correctly I need to move the wheels first to the 2 "Axle" Image Points of the chassis.
But moving a wheel to its axle causes a bump and move the chassis.

How can I "construct" the car upon an event in such way I can let it drive away?

Thanks
B
6
Posts: 10
Reputation: 274

Post » Tue Apr 29, 2014 9:56 pm

pin object?
B
17
S
7
Posts: 360
Reputation: 2,202

Post » Wed Apr 30, 2014 6:29 am

Hi, thanks for your response.

I don't think that will work since pinning the wheel to the chassis does not move it to the Image Point.
When moving the wheel towards the chassis after pinning it, it pushes the chassis away (in Pin -> Bar mode).
Other Pin modes have other effects, but none results in attaching the wheel to the chassis without applying force to it and causing movement.

Anyone another idea in how to solve this?
B
6
Posts: 10
Reputation: 274

Post » Wed Apr 30, 2014 1:57 pm

Have you tried disabling collisions between the wheel and chassis .
What I know would fill a Book , what I don't know would fill a Library
B
37
S
12
G
29
Posts: 331
Reputation: 16,499

Post » Fri May 02, 2014 10:17 am

Is it possible to disable collisions between two specific object types?

I tried to simply set the collision property to disabled for the two objects (should not collide with anything anymore?) but that has no effect.
The wheel still pushes the chassis away...
B
6
Posts: 10
Reputation: 274

Post » Mon May 05, 2014 9:35 am

Have you try setting Imagepoints?
B
257
S
42
G
15
Posts: 1,991
Reputation: 41,411

Post » Mon May 05, 2014 9:55 am

Yes, I have. I use them in the creation of the revolution joint.
Do you have a small working example? => two circles (wheels), one bar (chassis) with two imagePoints for the wheels.
All laying apart on a floor, then on click anywhere, put the wheels and chassis together to become a 'car'.
All with physics enabled so when the car gets an impulse, it will move nicely.

Thanks
B
6
Posts: 10
Reputation: 274


Return to Beginner's Questions

Who is online

Users browsing this forum: No registered users and 0 guests