-
-
Notifications
You must be signed in to change notification settings - Fork 21.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shouldn't PhysicsMaterial properties correspond to individual shapes rather than the body? #25254
Comments
I guess it could make sense except that shapes are not used on bodies only. And is not your rubbed tipped pencil consisting on the solid and the bouncy part? pinned by a joint? |
If I wanted the rubber part to detach when hit with force then I might consider using a joint, but otherwise a joint doesn't seem appropriate. |
Agreed, we could note this for 4.0 compat breakage.
…On Wed, Jan 23, 2019, 09:44 hedgehog90 ***@***.*** wrote:
If I wanted the rubber part to detach when hit with force then I might
consider using a joint, but otherwise a joint doesn't seem appropriate.
It makes perfect sense to me that you'd find the physical properties on an
individual collider/shape, than the all encompassing body.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#25254 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AF-Z25n8NPnjfYxnGDOG0oI1Ma4EWOAJks5vGFkjgaJpZM4aOlAV>
.
|
I wonder if this works in Bullet, though..
…On Wed, Jan 23, 2019, 10:11 Juan Linietsky ***@***.*** wrote:
Agreed, we could note this for 4.0 compat breakage.
On Wed, Jan 23, 2019, 09:44 hedgehog90 ***@***.*** wrote:
> If I wanted the rubber part to detach when hit with force then I might
> consider using a joint, but otherwise a joint doesn't seem appropriate.
> It makes perfect sense to me that you'd find the physical properties on
> an individual collider/shape, than the all encompassing body.
>
> —
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <#25254 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AF-Z25n8NPnjfYxnGDOG0oI1Ma4EWOAJks5vGFkjgaJpZM4aOlAV>
> .
>
|
I want to highlight that, in other engines (like UE4) when you use a compound body, internally the engine add many bodies with only one shape. In Godot you have the possibility to have many shape under the same body and you are noticing this "problem" because Godot give you more freedom. So to solve it you can just simply add more bodies with only one shape. (Side note, is better to not have 1 body with hundreds shapes to improve the performance). However is possible to add this feature at cost of work time and engine performance. |
In this case you are forced to use a joint, or even better spawn the rigid body when the part breaks |
Compound body nodes seems the way to go then.
I was watching a youtube video earlier demonstrating the Bullet physics engine in Blender, in which a compound option is shown, so it's definitely possible and probably not too difficult to implement: |
It doesn't allow to add custom friction per shape |
Not much new here in the past 3 years, though this is being tracked as a potential future enhancement in the above two tracker issues. In the meantime we've moved feature proposals to https://github.com/godotengine/godot-proposals/issues, I think it would be worth it to do the same for this proposal so that users interested in this suggestion can find it and indicate their support/provide feedback/implement it. |
Please open a proposal for this feature request. |
Am I missing something here?
It seems you can't have a single body consisting of multiple shapes with multiple physical properties.
For instance, if I wanted to create a somewhat realistic rubber tipped pencil in a physics simulator, the rubber tip would need to have a bouncier, rougher quality than the rest of the pencil.
It appears however that this is not possible without creating 2 bodies and putting a rigid joint between them, it doesn't seem right.
In Unity and other physics engines I've worked with, the Shape/Collider has the PhysicsMaterial equivalent properties, not the body.
Apologies if this is the wrong venue for this type of discussion. I asked about this on the community forum a while ago but got no replies: https://godotengine.org/qa/28594/rigid-compound-body-consisting-multiple-physical-properties
The text was updated successfully, but these errors were encountered: