system
1
|
|
|
|
Attention |
Topic was automatically imported from the old Question2Answer platform. |
|
Asked By |
TheRadMatt |
How to properly use joints in order to make loose objects that are affected by gravity, and are connected to another Rigid_Body?
Here’s a project that can be used for testing: Lamp_Physics.rar.
Example (the little ring on top):
system
2
|
|
|
|
Reply From: |
Zylann |
You can use the PinJoint
node, which will act like the attachment point at the top of your lantern.
This node can be placed in the world, and you have to specify two other nodes:
- The loose object, which should be a
RigidBody
- The object it is attached to (can be a
StaticBody
or another kind of body I guess).
It works the same in 2D.
Example project (for both 3D and 2D):
http://zylannprods.fr/dl/godot/LooseObjectPhysics.zip
This old video also explains it: https://www.youtube.com/watch?v=rYJB73eO8Mg