EbiNaki
2Snacks
2Snacks

patreon


Progress Update #52

Nope, couldn'tdo it. I'm gonna need another two weeks after all :p

I was pretty confident last weekbecause I animateda lot of stuff in Maya, but when I started exporting the scenes to Unity I ran into a bunch of problems, and I ended upspending most of my time troubleshooting rather than animating the rest of the episode. Here are some of my issues:

Limited animation playback in Unity: You can only preview one animation controller at a time in Unity. That becomes a big issue when you have multiple characters with different animation clips interacting with each other because the moment you select any other object in the scene the timeline changes, the preview animation stops, and the character pose resets back to the first frame. So you just end up doing a lot of guesswork and switching betweencharacters, and it's a real pain in the ass to animate the camera in a scene where you don't know the exact position of the characters. You do have the option to run the game, pause and then make changes to the scene, which sounds great, but the editor slows down to a crawl and it's very hard to move things around in the viewport, it's not a good way to work. My best solution for this problem is to animate everything together in Maya, including the camera (which has to be parentedto an object) and just exporting everything again into a new FBX. Now I just try to avoid doing any character animation inside Unity if possible.

Texture animation in Unity: I assumed that Unity handled texture animation just like Mayadid, and that was a big mistake. You can't export UV animation from Maya, and you can't directly animate materials in Unity, you can only animate the UV offset and scale of a specific mesh, so even if you have multiple materials assigned to a single object you have no individual control over them, everything gets animated. My solution was to split the characters faces into multiple objects (head, lefteye, right eye, and mouth) which allows me to animate the UVs individually, but it also creates a new problem, I lose the original smooth surface of the face:

And this seems to be a Mayaproblem with the FBX export, it doesn't preserve the smoothing groups of the objects when there's animation data in the FBX file. I tried a lot of different exporting options to solve the problem but the result is always the same. The solution to this problem was to manually replace the mesh renderer of each face object of the animated FBX with the objects of the static FBX, which is a really bad solution because I have to repeat the process every time I need a face animated, it just feels time-consuming and unnecessary. If I start another project with Unity in the future, I'm gonna have to find a better solution for this problem.

Not everything can be exported: You're limited to geometry and joint animation only, that means that any deformers, clusters or animation expressions that you have in your Maya model are lost when exporting to Unity. Even if you're using a standard rig you still have to bake the keyframes into the joints because the constraints and controls are not going to work. But to be fair, I think this is the standard for most game engines, it's not really a Unity problem, Unreal 4 probably works the exact same way. There is a neat solution though, it's a tool used to store scene data called Alembic cache. It goes through all of your animation and it saves the position of all the vertices of your 3D object for each frame. Depending on the polycount of your model it can create a very large file, but you don't have to worry about the joints or any of the deformers anymore because the Alembic cache only saves the geometry. This cache used to be something exclusive to 3D softwareslike Maya or Blender, but the Unity dev team released an Alembic importer/exporter last year, and it's now possible to easily bring these cache files over to Unity. it's a pretty good solution for fluid and cloth simulation, but I'm using it for my animation expression driven rigs and any other effect that uses the Maya deformers.

Despiteall of these problems, I still like Unity (Maya gives me a lot of headaches too). Thingsmight not be as easier as I was hoping, but it still is a pretty good workflow, especially now that I solved some of the problems. It's been two months since I started, most of the animation is done, and this episode is shaping up to be one of my favorites, so I can't complain too much!

Progress Update #52

Comments

I still feel a little bit dizzy when I'm laying down in bed and I tilt my head. But yeah, coffee is a problem for me too, so I've been avoiding anything with caffeine.

2Snacks

The more I see these updates, the more excited I am to see this episode lol

Red Fox

Most people would give up at this point. But not you. :)

Tradley

If you cant use the shader graph you can also use a script to change scale and offset of a single material on a mesh with multiple materials using script. the materials of a mesh renderer are stored as an array, so just add "public Renderer rend;" to a script. then use something like "rend.materials[0].SetTextureScale("_MainTex", size);" the [0] being the first material on the mesh

daveronald

I hope you're vertigo is all better now. I had the same thing about 6-7 years ago, took over month to get better. If your anything like me long/bumpy drives will bring it back, kind of afraid to ever go on a roller coaster again. I have also noticed if I drink a lot of coffee I can start to feel dizzy for a couple hours, I have seen other people say the same thing but there doesn't seem to be any medical documentation on this. Anyways keep up the good work.

daveronald

Are you using the HD render pipeline in Unity? if you are you can create a shader graph that allows you create flip-book sprite sheets and switch between textures on a single material, regardless of how many other materials you have on a mesh. you make variables to control everything public so that they can be edited by script (or possibly animation events). I have used this to create a changing tv screen. here is the youtube tutorial I watched <a href="https://www.youtube.com/watch?v=gEnsciDtbUQ&amp;t=529s" rel="nofollow noopener" target="_blank">https://www.youtube.com/watch?v=gEnsciDtbUQ&amp;t=529s</a>

daveronald

Very cool to hear and sorry that Unity and Maya aren't playing nice together. That said, glad you're figuring ut such neat workarounds. It's always cool hear this stuff. :)

The Ferret

Keep up the good work! This is what fans of SBF and MLP need since we are on the edge of Losing both with the mainline MLP show coming to an end soon with the Ninth season premiere this month. 2SNACKS YOU ARE THE ONE OF THE LAST HOPES FOR QUALITY FAN MLP RELATED MEDIA!

Scottpligrimrules


More Creators and Models