Forum rules - please read before posting.

Blend Shapes on NPCs

edited January 2017 in Technical Q&A

I have a NPC with Blend Shapes and a Shapeable script on his mesh. I have setup a Shape Group labelled Blink, with two keys: Left Eye Blink and Right Eye Blink. To start this Blend Shape, I have setup a massive trigger (there must be a better way) set to continuous and play during gameplay and cutscenes, which starts the Action List (see image).

http://imgur.com/je04dsu

I cannot get the "blinking" to work. This is in a 3d game, in Unity 5.4.



Comments

  • As both your keys are in the same group, enabling one with disable the other.  However, if all you're looking to do it have the NPC blink every X seconds, you can just animate that in an additive layer in their Animator.
  • @ChrisIceBox Ok, thanks. I've never done facial animation within Unity before. What do you think is better performance-wise, using looping actions, or your suggestion of using the animator (if there is any obvious difference)?
  • The Animator is definitiely the best way to go
  • Hmm... Not sure how to get the Animator to control the Blend Shapes. Since the Blend shapes are on the actual body mesh of the npc, but the animator is on the parent object?

    I made an animation clip of the blinking, and made another state called blinking on the animator's additive layer, and put the blinking clip into the motion panel. This does nothing though, so I am going wrong somewhere.

  • The Animator can control properties of child objects, not just the parent.  As you'll want it to work in tandem with other animations, you'll want it to be on an animation sub-layer, rather than the base layer.  This now becomes a general Unity-usage issue, however.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.