Search Unity

mecanim implementation issues - 3D character 2D face

Discussion in 'Animation' started by garbagepit, Aug 24, 2015.

  1. garbagepit


    Dec 5, 2012
    Hi All,
    I've got a thinker on my hands.

    I've got a 3D skinned modelled humanoid character with Sprite Textures for Facial expressions (one mouth, two eyes)

    Model is an FBX using maya 2012 exporter, after import it's configured as a humanoid and facial sprites are parented under the head bone.

    Mecanim Controller that can trigger bone animations and facial animation tracks (sprites turned off and on with the Animation editor)

    Methods I've tried:

    Method A:
    Imported animation tracks are duplicated (making them not read-only), keys are set for one set of eyes to turn off and the other on.

    works fine except for transitions, when in a half state both eye sets want to be on at the same time. So bones blend nice, eyes don't. I found a temporary fix is to just speed through transitions, you don't notice the funky transition as much, but your transition blend between poses/clips is jerky.

    Method B:
    Making a Eye/Mouth Layer. So with a blank animation track with JUST animation of mouth's eyes turned on and off for different states. I set up a trigger so that both base layer and eye layer gets triggered at the right time.

    if I'm in override mode even with nothing animated on the bones everything wants to go back to default pose. If I'm in additive nothing gets added back on.
    If i'm in override with a mask set to all it works! ... except there's a weird double transform where my character gets shoved to the right for some reason happens both with humanoid mask and custom transform mask set to none.

    I'm kinda settled on method a and just speeding through transitions for now, but It kinda defeats the purpose of the fancy mecanim blending that actually looks really good.

    thanks to anybody who takes the time to answer!