191
edits
(Added "Importing animations and preparing the Blender scene" header) |
|||
Line 30: | Line 30: | ||
Blender custom properties and '''drivers''' (drivers are used to set the influence of | Blender custom properties and '''drivers''' (drivers in the rig described here are used to set the influence of its controllers' bone constraints through the Pose1 and Pose2 bone locations): | ||
* [https://www.youtube.com/watch?v=_197jQFh22E Custom properties and drivers in blender made easy] by Pierrick Picaut | * [https://www.youtube.com/watch?v=_197jQFh22E Custom properties and drivers in blender made easy] by Pierrick Picaut | ||
Line 51: | Line 51: | ||
[[Blender#Rotation_order_issue_between_Oni_and_Blender|Please refer to THIS.]] | [[Blender#Rotation_order_issue_between_Oni_and_Blender|Please refer to THIS.]] | ||
=== | ===Broken alpha transparency and textures on animated models=== | ||
[[Blender#Broken_alpha_transparency_and_textures_on_animated_models|Please refer to THIS.]] | [[Blender#Broken_alpha_transparency_and_textures_on_animated_models|Please refer to THIS.]] | ||
==Importing animations and preparing the Blender scene== | |||
The actual tutorial starts here. | |||
For detailed explanation of the required OniSplit commands, please refer to the '''Oni-Blender Tutorial by EdT''' listed in the '''Tools and relevant tutorials'''. | |||
[[Image:ARB SceneUponImportingKonokos.png|400px|right|thumb|Expected result at point 9]] | |||
# Using OniSplit, export any character you want as a DAE (-extract:dae) using -noanim and -blender arguments. | |||
## As per EdT's '''Oni-Blender Tutorial''', you should get <mark><tt>AnimationDaeWriter: custom axis conversion</tt></mark> in OniSplit output if you've used the -blender argument. If you didn't get that on the output, it means something most likely went wrong and you won't be able to import the model into Blender (or you will be able to import it but it will be wrong). | |||
## Assuming you wanted a textured model and thus you've exported an ONCC, you should now get a '''DAE file''' and an '''''images''''' folder containing the textures for it. | |||
# Using OniSplit, export any two animations as an XML (-extract:xml) using -noanim (T-Pose), -anim-body (lets you specify the character you want) and -blender arguments. | |||
## You should get '''one DAE and an XML file for each animation, totalling four files.''' | |||
# Open up Blender and set your scene's frame rate to 60 FPS. If you don't, the keyframes of the imported animations will get tightened up together, because Blender's default scene framerate is 24 FPS. | |||
# Import the -noanim model into Blender first ('''MAKE SURE YOU CHECK THE ''Import Unit'' BOX''', otherwise you will import the model with arbitrary units which will break everything and will be basically unadjustable later) | |||
# Import the animations into Blender ('''ALSO MAKE SURE YOU CHECK THE ''Import Unit'' BOX EACH TIME''') | |||
# At this point the -noanim/T-posed model in the scene should have no suffix in its body part names, while the animated models should have ''.001'' and ''.002'' suffixes. This is intended; the T-posed model will serve for building the metarig and editing the rig once it's generated, while the animated models are needed for pose matching purposes, where the suffixes are useful for setting up the bone constraints. | |||
# Create three new collections in the Outliner, name them ''T-pose'', ''Pose 1'' and ''Pose 2''. These three collections allow you to quickly hide the respective models from the Viewport using the eye icon in the Outliner. | |||
## Move the T-Posed model to ''T-pose'', and move ''.001'' and ''.002'' animated models to ''Pose 1'' and ''Pose 2'' collections respectively. | |||
# If you've imported the textured model, [https://wiki.oni2.net/w/index.php?title=Creating_an_animation_rig_in_Blender&action=submit#Textures_on_animated_models apply textures to the animated models and fix the alpha transparency issue.] | |||
# At this point, your scene should look like in the screenshot on the right. | |||
[[Category:Modding tutorials]] | [[Category:Modding tutorials]] |
edits