This skill helps you attach meshes to bones in a skinned mesh, enabling precise weapon placement and animated props.
npx playbooks add skill verekia/r3f-gamedev --skill bone-attachment
Attach meshes to bones of a skinned mesh, such as attaching a sword to a character's hand.
Create a BoneChild component that uses useEffect to add a container group to a bone and remove it on cleanup. The bone reference is obtained from the GLTF nodes after loading the model.
nodes.HandR)bone.add(container) to parent objects to bonesbone.remove(container) in useEffect cleanupconst { nodes } = useGLTF('/character.glb')
<BoneChild bone={nodes.HandR} position={[0, 0.3, 2]} rotation={[0, 0, 0]}>
<mesh>
<boxGeometry />
<meshBasicMaterial color="red" />
</mesh>
</BoneChild>
---
This skill is part of [verekia](https://x.com/verekia)'s [r3f-gamedev](https://github.com/verekia/r3f-gamedev).
Weekly roundup of top Claude Code skills, MCP servers, and AI coding tips.