CakeLord's Koikatsu to VRChat tutorial (2020) Version 0.8.1

This tutorial expects that you know the very basics of using Blender and understand the process for exporting models.
It is recommended to watch Tupper's Megatutorial for a general guideline; Many of the things taught there are used here.
https://www.youtube.com/watch?v=7P0ljQ6hU0A

Use the latest BetterRepack for Koikatsu, it should have the Material Editor mod and PMXExport.dll.
Make sure PMXExport is within your BepInEx folder in your Koikatsu install directory.
Use Blender 2.79 and CATS Plugin.
Use Photoshop CC and Paint Tool SAI or equivalents.

[In Koikatsu]
Koikatsu's shader is oversaturated so when exporting, look at the color in the bar instead of on the model.
Accessories tend to link to one bone and get exported as such, leaving many materials to share their weights in just one vertex group;
Counter this by relying less on accessories or exporting multiple versions of the model and adding only the accessory to a main model.
PMXExport breaks mods upon initial load, You'll have to enter and exit the character creator once before the mods start working again.
To have an easier time working, leave PMXExport out of the BepInEx folder until you're ready to export your model.
1.

[In Blender]
Make multiple saves throughout the process to save yourself time if any errors occur.

  1. Load model with CATS.
    1a. Set MMD Shading to Shadeless in your Secondary Tab(N key).
    1b. Blender has a tendency to break your shading for no reason when combining materials, so enable GLSL to check.
    1c. Always set your shading to Smooth in Shading under the Tools Tab in the top left corner.
  2. Separate by Materials.
    2a. Hide the Armature.
  3. Go through every material and set the correct textures.
    3a. In KK, use Material Editor on every part of the outfit, body, and accessory and extract the Main Tex, Detail, Normal and Color Map.
    3b. Arrange your textures in this order: Normal, Detail, Main Textures, and Colors.
    3b-1.In Textures, under Influence, set the blend mode to Mix for Normals, Linear Light for Details, Multiply for Main Tex, and Linear Light for Colors.
    3b-2. Enable RGB to Intensity for Linear Lights and color the texture as you wish.
    3b-3. Detail textures are best set at 0.4 brightness.
    3c. In Photoshop, load in your color maps and go to Channels in the bottom right and select Split Channels from the dropdown menu (the down arrow and three lines in the corner).
    3c-1. Use Hue/Saturation under adjustments to set each channel as white and then save them as new PNG textures. Name them as you wish.
  4. Fix the eyelash textures in Paint Tool SAI by combining them into one 2-layer texture and adjust saturation to black.
    4a. Delete "cf_m_eyeline_down", This material is superceded by the "up" version.
    4b. Delete "Standard (Instance)" as well, this is a material that is only used for shading in koikatsu.
  5. In Photoshop, adjust the color of the lip texture and resize it, then place it on top of the face texture. This may take many attempts.
    5a. Use Hue/Saturation or Color Balance under Adjustments in the Image tab at the top of Photoshop.
    5b. Use the Move Tool(V) to grab and drag the lip texture over to the other tab with the face texure.
    5c. From there, resize by clicking on the corners of the active texture and fit it to the best of your abilities.
    5d. Add the nose line as well to the face texure, this is optional.
  6. Adjust the color of Diffuse under Materials for hair.
  7. Join all materials in CATS.
  8. Select the Armature and adjust the Z coordinate so that the model is flat on the floor.
    8a. Use Pose mode to fix the foot rotation if you're using high heels.
  9. Fix Model with CATS. This may take some time.
  10. Re-enable any textures that were turned off.
  11. Go into edit mode for the Armature and parent bones.
  12. In 3D View, select the hips and parent the Siri(butt) and SK(skirt) bones with Bone Parenting in CATS.
    12a. Bone Parenting creates Root Bones that we use later in Unity to set Dynamic Bones on more efficiently.
  13. Go through the Armature and select any unwanted bones and use "Merge Weights: To Parents", under Model Options.
    13a. Start from the lowest point in the chain when doing this.
  14. Parent the breast bones in this order: Bnip02, Bnip25, Bnip15, Bnip01, Bust3, Bust2, Bust1.
    14a. To parent bones together, Use this key string: Left Click Bnip02, Shift+Left Click Bnip25, Ctrl+P, Keep Offset.
  15. Merge Weights on the last three bones in the breast chains.
    15a. Use Bone Parenting in CATS to parent the Bust01(breast) bones to the chest.
  16. Make sure any rings or bracelets are parented and merged to the correct bone.
  17. Find the hair chains and the "Eyex" bones and parent(Ctrl+P) them to the head bone.
  18. Merge Weights on every other bone in the head heirarchy.
    18a. The face has so many bones that control individual parts of the face, they won't be used unless you're making your own unique shapekeys.
  19. Test any bone chains with pose mode and Merge Weights to reduce bone count.
  20. Use Bone Parenting in CATS to parent the HairB_Top(Hair) bones to the head.
  21. Separate by Materials once again.
  22. Combine all the skin, clothes, face parts, and accessories into their own respective material.
    22a. Use Ctrl+J to join materials and set up 4 main materials.
    22b. The last material you select is the one all other materials combine to.
    22c. If you're using Normal Maps or Matcaps on certain parts of the outfit, go into edit mode and press "P",
    then separate by selection on all the verts you want to use a Matcap on and recombine them all into another main material.
    22d. The nipples can be done two ways, placing the nip texure on the body directly in Photoshop, or adding the nip as its own mesh and material
    with the "emblem" bra option.
    22d-1. The 1st method requires you either redraw or recolor the nipple texture then add it to the skin atlas after its been made.
    This 1st method result in a blurry texture for the nipple on the body but saves material slots for other things.
    22d-2. The 2nd method requires you to export a second model with the "heart shaped pastie" bra on your model, you then switch the heart texture
    with the nipple in blender and adjust its XYZ coordinates for one breast, then delete the other. You then repeat the process for the other breast.
    This 2nd method will give you a higher quality nipple texture but it must be on its own atlas due to transparency issues.
    22d-3. The 1st method is best for small chests, where the textue isn't so stretched on the mesh. The 2nd is best for large chests.
  23. Go into edit mode and select by materials, press "W" and Remove Doubles.
    23a. Do not remove doubles on the face or any part that has shapekeys you want to use. They will be broken.
    23a-1. Removing Doubles may break your normals, so use it only if you're trying to lower polycount and deleting verts isn't an option.
  24. Delete any unwanted verts. This can be parts of the body that can't be seen or textureless verts.
    24a. If you want to use more outfits for this model, save here and keep the nude mesh, we'll come back to it later.
  25. In the Render tab(Camera), open Bake and Texture Atlas and set Bake Mode to Textures.
    25a. For the Skin Atlas, set the Bake Margin to 64 px. The rest can be left at 16 px.
    25b. Atlasing can be very time consuming, so make sure to save before, during, and after any attempt.
  26. Select the material you want to atlas and press the Plus Icon in Texture Atlas and name the atlas how you want.
    26a. Set the resolution to 2K or 4K, then press Start Manual Unwrap, wait for the process to complete and then press Finish Manual Unwrap.
    26b. Close the tabs on the left and right of your 3D View and grab the top right corner in your 3D View(the diagnal slashes)and drag to the left.
    26c. Now with two 3D Views, set one to UV/Image Editor by clicking the gray cube in the bottom left corner.
    26d. Select your material and switch to edit mode. In your UV View press the cube with a mouse icon on it(UV/Mesh Sync).
  27. Go to your Materials tab and Select the material you want to move and reorganize all your materials so they fit within the box.
    27a. Use "G" to move, "S" to Scale, and "R" to rotate the materials; The X, Y, and Z keys can all be used to affect only one axis of movement.
    27b. Textures that have more importance, like jackets or the body, should be bigger.
    27c. Textures with little or no detail, like ribbons or teeth, can be made very small to save space.
  28. Once done, go back to Render and press Bake; If you have alpha channels, you'll have to bake twice.
    28a. fix any spacing errors and re-bake if necessary.
  29. When done, Click Image at the bottom row and Save Image As a PNG.
  30. Close your UV tab and go to your Materials tab and delete all materials, then add a new material and use the new atlas texture.
    30a. Re-enable Shadeless MMD Shading if your texture is black.
  31. Go to your Data tab and delete "UVMap", then rename the atlas UV to "UVMap".
  32. Save and Restart Blender after finishing an atlas, it may crash if you try to atlas twice in a row.
  33. Once finished with altasing, go into edit mode and fix or remove any verts that are out of place.
    33a. The chest and arms suffer from a lot of clipping with the clothes.
    33b. Use the Sculpt Tool, Proportional Editing, or manually grabbing verts to fix these issues.
    33c. Select the verts and use Shape Propagate(W) on the Basis shapekey to fix any verts that are moving incorrectly when you test shapekeys.
  34. Join all materials in CATS and create new shapekeys in the Data tab.
    34a. Combine multiple shapekeys by using the black triangle next to shapekeys and select "+ New Shape From Mix".
    34a-1. Make sure to set all shapekeys to 0 after creating a new mix.
    34b. Koikatsu models have over 400 shapekeys, but most of them are labeled in a simple to understand way.
    34b-1. Some examples of shape mixes you'll want to make are this:
    "eye_face.f00_def_cl 0.7" + "eye_line_u.elu00_def_cl 0.7" = Closed Eyes.
    "eye_face.f00_egao_cl 0.7" + "eye_line_u.elu00_egao_cl 0.7" = Happy Closed Eyes.

34c. While there are teeth shapekeys, I find its easier to just resize the teeth at the end after making all the mouth shapekeys.
34c-1. It is more time consuming but gives a better result. Creating a "Hide Teeth" shapekey is also very useful.
34c-2. Using "Hide Teeth" prevents the teeth from blowing out of your mouth when you use multiple gestures at the same time in VRChat.
34c-3. The tongue is the same way; Readjust it manually for better results.
34d. Press W and use Shape Propagate to set the tongue's placement on all shapekeys.
34e. Depending on the shape of the face, the eyelashes may be clipping heavily in your shapekeys.
Fix this by selecting your shapekey, entering edit mode, then grabbing the verts and pulling them along the Z axis until they're outside the face.
34e-1. Eyes that are heavily angled in one direction will have major clipping. This is very time consuming to fix.

  1. Use CATS to create visemes and eye tracking.
    35a. You'll need an "Aa", "Oh", and "Ch" shapekey for visemes.
    35b. The eyes are exported in their default size from Koikatsu, you'll need to resize them in edit mode.
    35b-1. The eye whites can cause a lot of clipping, resize them as well. Make them bigger, pull them back, then bring their edges closer to the inner eyelids.
    35b-2. Delete the single vert that closes each eye socket, it causes many issues with clipping and eye tracking.
    35b-3. You can also remove the innermost layer of the eyelids as well. This is optional.
  2. Select everything in Edit Mode and sort your materials in the Materials tab.
    36a. Use the arrows above Deselect to organize your materials, make sure transparent materials are at the top.
    36a-1. An exaple: Face(Transparent), Skin(Opaque), Accessories(Transparent), Clothes(Opaque).
    36a-2. Now, with every vert selected(A key), press the space bar and type "Sort", then select Sort Mesh Elements and sort by Materials.
    in the bottom left corner of your your Tool Shelf, select Faces in the new Sort Mesh Elements box.
    This is done to prioritize transparent texures in Unity and VRChat, without it, your eyes and other parts of the model may not correctly appear.
  3. Unhide all parts, save, do any final testing, and export the model as an FBX.
    37a. Make sure to see Tupper's tutorial for setting up the correct Operator Preset for exporting to VRChat.
  4. (Optional) If you saved your nude mesh, you can delete your outfit's materials and any bones tied to them(skirt) and then create a new outfit to export from koikatsu.
    38a. The process is the same but just make sure to adjust the bones in the exact same way for the new outfit.
    38a-1. Test and delete any bones not tied to the new outfit.
    38a-2. The oufits do not need shapekeys, remove them or else they'll make the combining process take even longer.
    38a-3. You can atlas before or after combining the two models together, I prefer after.
    38b. With everything sorted, go into the CATS Tool and open Custom Model Creation, make sure all options are enabled and that your nude model is set as the base then combine.
    This may take longer depending on how many bones, materials, and shapekeys Blender has to process.

[In Unity]

If you're building in 2018.4.20f1, you need to enable "Legacy Blend Shapes Normals" under Model, in the inspector. Without this, your model's normals wil flip constantly in VRChat.

  1. Create a folder for your new model and name it howerver you want.
    1a. Create three sub folders named: Animations, Materials, and Textures.
  2. Add your textures in first, then add your FBX.
    2a. In your inspector, under Rig, set the animation type to Humanoid for your model.
    2b. Save your scene and configure your model in Rig.
    2c. Set the bones correctly, the chest and eyes are usually incorrect.
    2d. Clear the jaw bone, this will cause many issues with your visemes if enabled.
Edit Report
Pub: 23 Jan 2022 23:43 UTC
Views: 151