You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 29, 2022. It is now read-only.
Well, the title explains it: it would be nice to support joints and motors.
bevy_rapier implements these as separate entities. For example, one does:
let joint = BallJoint::new(Vec3::new(0.0,0.0,1.0).into(),Vec3::new(0.0,0.0, -3.0).into());
commands.spawn().insert(JointBuilderComponent::new(joint, entity1, entity2));
This seems like the most reasonable way of doing things. It is
My suggestion would be to have something like a "Joint" struct, containing the data necessary to construct a joint, including two entities. Then the "Joint system" could go over all the changed joint components each step, creating/modifying/deleting joints from the JointSet as needed. The motor configuration could either be a separate component or an optional part of the joint component (the advantage of doing it the second way is that the type of a motor configuration depends on the joint type - so this allows us to prevent people from adding incompatible motor and joints to the same entity).
Well, the title explains it: it would be nice to support joints and motors.
bevy_rapier
implements these as separate entities. For example, one does:This seems like the most reasonable way of doing things. It is
My suggestion would be to have something like a "
Joint
" struct, containing the data necessary to construct a joint, including two entities. Then the "Joint system" could go over all the changed joint components each step, creating/modifying/deleting joints from theJointSet
as needed. The motor configuration could either be a separate component or an optional part of the joint component (the advantage of doing it the second way is that the type of a motor configuration depends on the joint type - so this allows us to prevent people from adding incompatible motor and joints to the same entity).I'm imagining using this something like
I'm happy to take a crack at implementing this myself if this sounds like a reasonable solution.
The text was updated successfully, but these errors were encountered: