Hi everyone!
I have this character that has an animation of him drawing a knife attached to his thigh.
I'm using biped to animate the character, with a Prop bone for the knife. The knife does move from the thigh to the hand when drawn, however, it floats a bit before that, when the thigh is moving, since the position/rotation space settings are set on "Body".
So a few questions:
- i'd like to avoid using constraint animation since from what i understood it forbids animation export in .bip format (i'd be happy to be proved wrong though)
- is there a way to add another bodypart to the prop key rollout? For example, i have another character who draws his sword from his back.
- do i need to use two props attached in the same place to be sure the sheath stays in place when the knife is drawn?
Thanks!
Replies
1)From what I know you can add custom bone to biped
2)Why you don't keep animations in FBX files?
3)usually animators add custom points\dummy objects for things like swords and other probs, but again, to keep these animations you should use some newer format, not .bip
So basically there are three ways to handle this (that I can think of, off the top of my head).
1) Biped Prop Bone
Add a prop bone to biped and in the "biped menu > Key Info > IK > Prop" you can set a key and then assign and re-assign the prop bone to the left or right hands, or the world.
So while it's on the back or leg, you assign it to the world and "align and key" it to point that is linked to the bone you want to follow. This point will have the same orientation as your prop bone so you can align to it easily.
Then when you pick it up with the hand you switch the prop to follow the hand. This works pretty well for simple things like swords, but more complex weapons normally need a lot more rigging than what biped can pull off. How well this works really depends on your engine and the code you're working with.
2) Link constraint
You create a prop bone that isn't parented to anything. You apply a link constraint which will allow you to switch its parent to several objects in it's list and parent it back to the world, at specific keyframes. It would start out parented to the world on frame 0, then parent it to the leg or back at 5, then parent it to the hand at 50. IF this is compatible with your engine is totally up to it and whatever code you're working with.
3) Align and Key.
There are several scripts (Jim Jagger has a good one) that will align one object to another and create a key on each frame. Basically baking in the animation without ever using a constraint.
So you would do #1 but then take your final weapon rig that isn't constrained and Align/Key it to the one that is constrained. When you export do a "export selected" and don't select the constrained version.
This is pretty friendly with most engines but can be a pain to work, especially if you need to change the animation or if it blends with other animations that might be controlled by the player.
For example if the player speed controls a blend between walk/run and your weapon is on the thigh you never really know where the thigh will be so you can't bake an animation. But if the weapon is on their back and you can control the animation 100% between the spine and the arms, then it should bake fine.
Trial and error, wash rinse repeat until success!
Don't be scared of using complex rigs to drive your final rig.
1) You can add prop bones to biped, however they are fairly limited and won't parent to anything but the hands and the world. Making it difficult to parent it to the back or legs. But it is all selfcontained within biped so it works with all of it's systems, motion mixer, load/save, layers, copy/paste poses ect...
2) If he's using biped he would probably want to stick to .bip files while working. loading/saving animation on and off of a biped can be done using FBX but you can run into some problems too, .bip is a lot safer and pretty much rock solid. Final export will probably be FBX but working files will probably be .bip.
3) Biped has the option to save/load into the .bip files, max objects that interact with biped. So adding custom rigging to biped isn't too much of an issue. The motion mixer is also set up in a way that you can work with max objects and biped at the same time. You might save out your max objects to .xaf and biped to .bip but you can work with them in the mixer as tracks and get them to line up perfectly.
Can that be exported in the .bip file? The idea is that i would like to be able to load .bip like i want in my scene without having to tweak the constraint keys (and link up some animations together).
I usually get a message saying the bone is already child to another bone and that i should use a dummy instead or something like that (even when i do use a dummy, it doesn't work any better, i receive the same message).
I'm not using any game engine anyway, since i'm just rendering (pretty advanced) characters as a base for pixel art, but i want to keep it simple and pratical So the least i have to tweak keys, the better.