Hello. Tell me, please. I have a bone that controls 2.5d head rotation, separately I have large eyebrows, mustache and beard. And they have their bones on them. There are bones with physics on his mustache and beard. Is it possible to distort the moustache and eyebrows with a bone to turn the head and at the same time control the moustache and eyebrows through their own bones? If not, what would be the best solution for this?
Mesh deformation and bone rotation
Yes, it is possible to achieve the effect you are looking for by using a combination of mesh deformation and bone rotation. Here are the steps you can follow:
Separate Control Bones: Create separate bones for the head, eyebrows, mustache, and beard. Ensure that the head bone controls the overall 2.5D rotation of the head.
Mesh Deformation: Convert the mustache and eyebrows into meshes. This will allow you to deform them during the animation. You can bind these meshes to both the head bone and their respective control bones (eyebrows and mustache bones).
Binding and Weighting: Bind the vertices of the mustache and eyebrows meshes to both the head bone and their respective control bones. Assign weights to the vertices so that the parts of the mesh that should follow the head movement have higher influence from the head bone, while the parts that should follow the mustache and eyebrows bones have higher influence from those bones.
Physics Bones: For the mustache and beard, you can add physics bones to simulate natural movement. These bones can be influenced by the head bone for overall movement and by their own control bones for detailed movement.
Transform Constraints: Use transform constraints to ensure that the bones for the mustache and eyebrows follow the head bone's rotation and translation. This can be done by setting up constraints with appropriate mix values to achieve the desired effect.
Here is an example of how you can set up the constraints and weights:
- Head Bone (controls overall 2.5D rotation)
- Eyebrows Bone (controls eyebrows)
- Mustache Bone (controls mustache)
- Beard Bone (controls beard)
For more detailed control, you can refer to the Mix and Match example which demonstrates how to use multiple bones and meshes to create a 2.5D effect.
Additionally, you can check out the Spine User Guide on Meshes and Weights for more information on how to bind and weight meshes to bones.
By following these steps, you should be able to achieve the desired effect of controlling the mustache and eyebrows through their own bones while also allowing them to deform with the head rotation.
- Editado
q3olegka What you want to do is prevent the eyebrow and mustache from sticking out of the character's face when you move his head towards the back, right? If so, create a bone that moves in the opposite direction when the face direction control bone is moved, and then give the tip of the eyebrow and mustache meshes weights for that bone. You can create the bone that move in the opposite direction when a specific bone moves by using a transform constraint, as Spinebot has answered.
You may want to check out the Helmet available for download on the Twitch Archive page to learn how to set this up. As you can see in the video below, moving the nose
bone allows you to move the head in 2.5D, and the parts at the edges of the face, such as the eyebrows and eyes, have weights on a bone called the head-inverse, which moves in the opposite direction of the nose bone:
As is done with the Helmet's rig, it is okay to use only a few percent of the weight. Most of the weight is given to the eyebrow bone, and a small amount of weight is given to the bone that moves in the opposite direction of the face control bone, allowing you to animate the eyebrow while still controlling the orientation of the face.
Thanks for the detailed answer. This should help me