<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Franciszek Machalica on Medium]]></title>
        <description><![CDATA[Stories by Franciszek Machalica on Medium]]></description>
        <link>https://medium.com/@f.machalica?source=rss-dd3df82b9e9e------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*DueEHigz4id9rCo1</url>
            <title>Stories by Franciszek Machalica on Medium</title>
            <link>https://medium.com/@f.machalica?source=rss-dd3df82b9e9e------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 00:00:03 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@f.machalica/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Unity and Maya character cloth workflows.]]></title>
            <link>https://medium.com/another-angle/unity-and-maya-character-cloth-workflows-e480e1f7afd?source=rss-dd3df82b9e9e------2</link>
            <guid isPermaLink="false">https://medium.com/p/e480e1f7afd</guid>
            <category><![CDATA[gamedev]]></category>
            <category><![CDATA[design]]></category>
            <category><![CDATA[simulation]]></category>
            <category><![CDATA[indie-game-dev]]></category>
            <category><![CDATA[3d]]></category>
            <dc:creator><![CDATA[Franciszek Machalica]]></dc:creator>
            <pubDate>Fri, 27 Dec 2019 15:17:40 GMT</pubDate>
            <atom:updated>2019-12-27T15:17:40.395Z</atom:updated>
            <content:encoded><![CDATA[<h3>About the author.</h3><p>I’m just a regular, everyday 3D generalist. Most of my experience comes from postproduction, commercial and feature movie background. Been involved with game production for a relatively short time. Heres my thoughts about Unity cloth workflows that I’ve have been testing.</p><h3>The start — native Unity tools.</h3><p>Cloth component. By default it requires a skinned mesh renderer component — so the natural reaction for me was “Perfect!”. That is exactly what I need. So I assumed that I should push the skinned mesh from Maya on a rigged character and separate the meshes that I want to behave like cloth. All that is left to do is add a cloth component, add colliders on character skeleton, tweak it — and we are home. Well, I was more than wrong. At some level of simplicity that workflow might actually work. It is a level I would say of a cape. Not even a hero cape.</p><p>It worked with a few characters from our game <a href="https://store.steampowered.com/app/1173980/Shadow_of_the_Road/"><strong>Shadow of The Road</strong></a>, but things got really messy with Akira — he has a slab armor on top of his pants, and on top of that armor he has two decorative bands.There is also a decorative skirt between the pants and slab armor…. We left the pants straight as a skinned mesh. No dynamic components. The armor was turned into a rigid body chain. It collided with the sphere collider on skeletons hips (character bottoms if I may) and capsule colliders on thighs. Rigid body worked fine after some tweaking and super helpful hints from our Technical Director. But adding cloth components on top of that was an… undoable task. It just didn’t work for some odd reason.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uUwJKxKalYZgTFydmWmdEQ.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_m5KRrxJZ-kuauhrE6Dakg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WHCgE7HidSHftlA1WqvAnw.jpeg" /></figure><p>To make things even more twisted — we migrated the project to Unity 2019.x … and all the workflow got blown away. We started to get awful artifacts on anything that was skinned mesh and had a cloth component. That moment I realized that I have to change the workflow because none of the tricks inside Unity performed correctly, also me making the mesh perfect in Maya for export didn’t work. To make things working again we had to find another way.</p><p>CONCLUSION :<br>At my level of expertise and my Unity experience level close to zero, the native Unity cloth component feels fantastic for relatively simple things like flags, curtains or maybe some capes and simple hairstyles. It is a quite intuitive and fast iterating tool. But on the level of my expectations of how it was supposed to act — either because of my lack of skills or because of the way I wanted to use the tool, everything was in the way of getting a perfect cloth simulation on a character.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*HoHMaz_JrHvgNG5f14TgjQ.gif" /><figcaption>Unity built-in cloth component in action</figcaption></figure><h3>Maya nCloth dynamics.</h3><p>This technique has a more natural feel for me. To be honest I was pretty sure from the beginning that this was the only correct way to make character cloth simulations. That would include:<br>1. Simulating medium to high-quality sim. <br>2. Exporting to point cache.<br>3. Playing the point caches with animation. <br>This workflow comes from my background and usually works fantastically in terms of simulation as it is. Exporting pre-simulated cloth elements had to be done through an alembic but it was still not a problem. Once we are in Unity reading and playing with the alembic, the object still works fine. Problems arise when the gameplay characters need to switch from one animation (simulation) to another. What is happening is those “jumps” between the sims. To make it look smooth and seamless, we would probably have to blend simulated meshes on the vertices level. That brings us two problems — I don’t know if it is possible without a super custom-crafted scripting. Also, I’m not sure if we can get the same vertices numbers for every alembic export.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OhqDCwZHhRyvCVBdH0CNuA.gif" /></figure><p>Conclusion:<br>Yes, that’s a fantastic way to get perfect simulations for example for in-game cinematics. You can easily play with and control the alembic files and characters from the timeline. But as for gameplay, it creates a few problems that are possible to overcome but our Technical Director is very worried about it. Firstly, because of the cost of writing the aforementioned scripts, secondly because of the performance that might, after all, be killing the entire flow.</p><h3>Unity third-party plugins.</h3><p><a href="https://assetstore.unity.com/packages/tools/animation/dynamic-bone-16743">Dynamic Bone</a> works super fun with tails and jiggly body parts. Pretty simple to set up: select the bone chains, add a component and have fun. Quite a few sliders to adjust the overall behavior of the desired body or cloth part. But as usual, we ran into problems with collisions. With a skirt model and a skinned mesh render — the cloth-like behaviors were fine. It all went to hell when this and the knees were to collide with a skirt. A lot of intersections and imperfections that were far from the desired effect. The ideal model might work fine if we make the bones of a skinned mesh dense — but it is always at the cost of performance.</p><p>CONCLUSION :<br>A fantastic tool for jiggly body parts, secondary animation, tails, etc… but not a perfect tool for cloth simulation. Still requires some more research and development form my side, but looks promising. Most probably I’ll take a deeper look into it shortly.</p><h3>Maya dynamic bones. <br>Because why not make things harder for yourself.</h3><p>Well … Yeah, we did go that way. The reason behind that thought was simple. If dynamic bones have a problem with collisions but act nice in terms of cloth-like simulations and performance, then what if we supply it with bone animated cloth and add on top of that baked animation.<br>“Dynamic bones” for secondary animation. Sounds good and like a perfect solution and mix of everything above. Ok, let’s do this. First, a quick setup of a skinned piece of cloth in Maya, constrained to a hipbone, self-explanatory and nothing fancy. Now convert all the bones under the “skirt root” to dynamic bones (you will need Maya bonus tools for that). Remember that (as usual in Maya) the order of bones selection is super important — it determines the way our cloth will be created. So there we have it — a polygon mesh, skinned with bones and bones animation driven by cloth simulation. It sounds very unstable and unpredictable to me, but it works. More or less, as usual, collisions are the tricky part. This setup gives us one fantastic privilege — we can bake “cloth simulation” into bones — and transfer it to Unity. FANTASTIC (in theory). So now the second part of the sneaky plan. On top of that baked bones we add dynamic bones for a secondary cloth-like simulation. So as before, select the first bones in every single chain and add the “dynamic bones” component. Yes, we came close but, no not really. “Dynamic bones” component works fine on bones that are not keyed. Once we have baked into the keys, we lost all the possible dynamics. The solution to that would be baking the bones that require collisions and leaving all the rest unbaked. Still not a perfect solution.</p><p>CONCLUSION :<br>First — in my personal experience and practice anything that is too complicated and too expensive (time = money) has no right to exist in a production pipeline. But if you get a perfect and easily tweakable setup it is sometimes worth it. Not in this case, unfortunately. This pipeline is worth exploring, but in my opinion only for academic purposes. Production-wise it is too complicated for a small scale studio like ours.</p><h3>GENERAL CONCLUSION</h3><p>Cloth simulation is always a very complicated thing — both in VFX or games. The best sims you can see in the cinematics of most AAA games, but in the actual game it is usually adequate, but never perfect. We, as a studio, will still work on all of the cases above to figure out the best way to do it — but I’m ready to admit that it is always going to be the middle-ground between AAA cinematics VFX and the in-game real-time engine for a small indie game studio like ours. Some real conclusions will come sooner than later — follow us to find out what finally turned out to be the best solution.</p><p>Talk to you soon!<br>Frank from <a href="https://medium.com/another-angle">Another Angle Games</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e480e1f7afd" width="1" height="1" alt=""><hr><p><a href="https://medium.com/another-angle/unity-and-maya-character-cloth-workflows-e480e1f7afd">Unity and Maya character cloth workflows.</a> was originally published in <a href="https://medium.com/another-angle">Another Angle Games</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>