-
-
Notifications
You must be signed in to change notification settings - Fork 3.9k
🧪 Bone attachments #18262
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
base: main
Are you sure you want to change the base?
🧪 Bone attachments #18262
Conversation
…target_ids` to `GltfLoaderSettings`
@alice-i-cecile any template on how to make the release note? |
We're kind of in flux right now, but for now, putting a
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good generally. Note to @alice-i-cecile : this PR solves one of the two use cases mentioned in the original issue, so unless we want to split it into two separate tickets, it should not close the issue once merged.
that is why i wrote |
@alice-i-cecile given how early this is I think it is best to add |
Can someone help me understand why we can't just use BSN overrides for this? BSN should have the ability to say "I want to load scene X, but add my own custom entity as a child of object Y". That's core to the concept of what overrides are. Once we do that, this feature should naturally fall out, no? |
@pcwalton for skinned meshes there are other things needed for it to work, not just parenting, I'm preparing another model to actually show that this works for skinned meshes |
Objective
Starts work on #17114
Solution
Create a new crate
bevy_bone_attachments
and implement a extension trait onEntityCommands
to allow attaching a newScene
to anEntity
. The command then collects allAnimationTarget
s of the entity and copies it to the newScene
.This is very early and only includes the above method, the new crate can also be included on an existing crate.
Testing
Showcase
Bone attachments allow you to attach a mesh to another, think a character holding a weapon, or customizable clothing.
Experimental: The current state only allows attaching new scenes into models, and requires that the parent entity is already fully loaded (if it is also a scene, after its
SceneInstance
is ready) and have matchingAnimationTargetId
s.Screencast_20250312_094221.webm
Use Guide