As title of topic inquires, I’ve been wondering how to how animate materials in Unreal Engine 4 so that I give life to my character model’s 2D facial features. You see, when I created my model in Blender I had the model rigged with the UV Warp modifier that would allow the pupils to move around by following the movement of a designated bone. Unfortunately though, none of Blender’s modifiers transfer over to Unreal Engine which means I can’t use the UV Warp modifier to animate the eyes of my character.
I’ve read that you can animate materials in Unreal Engine and so I was hoping that I would be able to animate my character’s pupils to move for certain animations. I was also hoping to able be to swap out the eyelid(s) texture with a variety of different ones to further my character’s range of emotional expressions, seeing as other than body language, his eyes are pretty much the only way he can communicate his emotional state.
So does anyone have any idea of how can be done? Any help whatsoever would be of a great help to me!
I found video [2D Eyes Maya to UE4 - YouTube] which shows pretty much what I’m trying to go for, but unfortunately the video doesn’t show the process of how its done. As for Flipbook, I guess I could the animate the eyes that way, its just I would probably have to make a ton of frames in order to avoid having the eyes move in a very choppy manner. I did come across video for how to animate textures with Flipbook [Unreal Engine 4 Tutorial: Animated Materials / Flipbook - YouTube]](Unreal Engine 4 Tutorial: Animated Materials / Flipbook - YouTube) but I would rather use the Flipbook method as a last resort & go with a method of being able to shift the pupil texture around the surface of the eye area. I still need to use Flipbook for a myriad of other things though, like adding blinking to my character or rotating spiral eyes for a character who is stunned.
**EDIT: **I also found video [UE4: 2D eye rotator - YouTube]. Is what I’m looking for or would it not work for my purposes?
There are several ways to approach , you can either:
a) make the eyes a separate plane that’s close to the head and use dynamic materials and change the texture based on what the character is doing
b) make the eyes have their own bones, in the animation blueprint use a transform rotator or IK setup to rotate them to face a specific direction (can be calculated based on player pawn and the other actor, like “find look at rotation” node for example)
c) make the eyes a spritesheet, extract them and create flipbooks, then on the character add it as a new component, attach it to the head, then in the blueprint create a new function like update flipbook or something along those lines, where it would set it based on whats happening with the character (happy, hurt, angry, etc.)
d) again with the eyes having their own bones, but add new keyframes to existing animations using persona
c) animate them in blender and export as part of the animation
e) look into control rig and have them rotate only during sequencer cutscenes
f) plan F, as in totally f… is to buy an iphone and check out the facial expressions demo and make a custom head with all the bones required and record new animations that way
There are probably more ways, but those were on top of my head how I would experiment with it.