-
Notifications
You must be signed in to change notification settings - Fork 3
06. Adding Clothing
This assumes you've set up a .blend file.
Clothing is a bit more complex. If you don't have blender experience at this point, you're really going to struggle.
Once again, let's start with an existing mesh:
- In your
.blendfile, go toFile->Append - Double-click into the
Yinglet-Clothes-Misc.blendfile - Click into the
Objectfolder - Click
Clothes-Glasses-Vizlet - Click
Append - It will bring in a copy of the rig and all the IK objects, you can safely delete all 6 of these by selecting them and pressing
X
- Rename the object as appropriate. I'm naming mine
Clothes-Glasses-Star
- Modify it to the desired shape.
- As with the hair, right click your glasses
- Shift right click the rig
- Hit CTRL-P
- Select "Armature Deform"
- As with the hair, go into edit mode, select all the vertices, and assign everything to the
faceVertex Group
2025-11-24.15-09-13.mp4
The glasses are simple and just use a basic grayscale ramp as their texture. Let's configure a material for this:
- Go to the Ucupaint addon
- Click "Quick Ucupaint Node Setup"
- Set the
TypetoEmissionand hitOK
- Under
Layers, click the (+) plus symbol and clickOpen Image... - Add the
Assets\Art\Materials\Entities\Common\SimpleGrayscale (64x64).pngimage
- Up near the top, add a
UV Editingworkspace
You should now see be able to edit the UVs:
Let's take a break for a moment to talk about how texturing actually works in Yinglet Creator.
Every single character creator texture is grayscale. This grayscaling is used as a color ramp for the actual user-defined colors.
Specifically, the colors are used at these points:
- 0% lightness: the texture will be black
- 25% lightness: the texture will be the
Shadecolor - 75% lightness: the texture will be the
Primarycolor - 100% lightness: the texture will be white
This graph may help clarify what I'm talking about:
If you're still confused, don't worry about it. All that's important is this:
- If you want something to appear bright, texture it near 75% lightness.
- If you want something to appear dark, texture it to 25% lightness.
In 90% of cases, you won't need to leave this 25%-75% range.
With this in mind, let's do the UVs for the glasses. Glasses use the color ramp directly, so we just need to unwrap it such that the vertices land directly on their lightness in the 25%-75% range.
With that done, we can export it back into Unity.
If you've done the other tutorials, this part should be familiar:
- Make a copy of the
ScriptableObjects/CharacterCompositor/CharacterToggleId/Clothes-Glasses/Clothes-Glassestoggle into your mod folder and give it a good name - Give it a good
DisplayName - Set the
Order->Indexto something later - Make a copy of the
Added Mesh Referenceand assign it - Modify this new
MeshWithMaterialsuch that theSkinned Mesh Renderer Prefabis our new mesh
Your assets should look like this:
And should be configured like this:
Note that we didn't have to define any
MixTextures. This is because we can safely piggyback off the existing ones. This has an added benefit: if the user changes their type of glasses, the colors will be preserved.
This is really the tip of the iceberg as far as clothing goes. However, the core concepts remain the same for all clothing:
- Create the models / textures in Blender
- Create a
CharacterToggleID - Configure it and any dependent toggles down the chain.
I've included two additional clothing assets in the sample app: a hat and a robe: