5
Instruction for importing motion capture animation into QuadD Last updated: April 21, 2020 1. After you apply captured motions to your character rig in Maya, export them as FBX files using the following file names: ANIM_CharacterBase_Standing_ Idle_01.fbx ANIM_CharacterBase_Standing_ TurnRight_01.fbx ANIM_CharacterBase_Standing_ TurnLeft_01.fbx ANIM_CharacterBase_Standing_ WalkForward_01.fbx ANIM_CharacterBase_Standing_ WalkRight_01.fbx ANIM_CharacterBase_Standing_ WalkLeft_01.fbx ANIM_CharacterBase_Standing_ WalkBack_01.fbx ANIM_CharacterBase_Standing_ RunForward_01.fbx ANIM_CharacterBase_Standing_ RunRight_01.fbx ANIM_CharacterBase_Standing_ RunLeft_01.fbx ANIM_CharacterBase_Standing_ RunBack_01.fbx ANIM_CharacterBase_Standing_ Jump_01.fbx ANIM_CharacterBase_Standing_ Fall_01.fbx ANIM_CharacterBase_Standing_ LandLight_01.fbx ANIM_CharacterBase_Standing_ LandHard_01.fbx ANIM_CharacterBase_Standing_ Damege_01.fbx ANIM_CharacterBase_Standing_ Death_01.fbx ANIM_CharacterBase_Crouch_ Idle_01.fbx ANIM_CharacterBase_Crouch_ TurnRight_01.fbx ANIM_CharacterBase_Croucg_ TurnLeft_01.fbx ANIM_CharacterBase_Crouch_ WalkForward_01.fbx ANIM_CharacterBase_Crouch_ WalkRight_01.fbx ANIM_CharacterBase_Crouch_ WalkLeft_01.fbx ANIM_CharacterBase_Crouch_ WalkBack_01.fbx ANIM_CharacterBase_Crouch_ RunForward_01.fbx ANIM_CharacterBase_Crouch_ RunRight_01.fbx ANIM_CharacterBase_Crouch_ RunLeft_01.fbx ANIM_CharacterBase_Crouch_ RunBack_01.fbx ANIM_CharacterBase_Crouch_ Jump_01.fbx ANIM_CharacterBase_Crouch_ Fall_01.fbx ANIM_CharacterBase_Crouch_ LandLight_01.fbx ANIM_CharacterBase_Crouch_ LandHard_01.fbx ANIM_CharacterBase_Crouch_ Damege_01.fbx ANIM_CharacterBase_Crouch_ Death_01.fbx 2. Download QuadD_Example.zip from https://utdallas.app.box.com/folder/105401641160 and unzip it. 3. Remove all the files in Unity_QuadDCharAnimDemo_Example -> Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase and copy the FBX files that you created in Step 1 and your character’s texture maps into the folder.

€¦ · Web viewSelect Rig_CharacterBase_Standing_Idle_02.fbx. Having Rig_CharacterBase_Standing_Idle_02.fbx in Inspector (the right side of the Unity window), Open Model tab, select

  • Upload
    others

  • View
    10

  • Download
    0

Embed Size (px)

Citation preview

Page 1: €¦ · Web viewSelect Rig_CharacterBase_Standing_Idle_02.fbx. Having Rig_CharacterBase_Standing_Idle_02.fbx in Inspector (the right side of the Unity window), Open Model tab, select

Instruction for importing motion capture animation into QuadDLast updated: April 21, 2020

1. After you apply captured motions to your character rig in Maya, export them as FBX files using the following file names:ANIM_CharacterBase_Standing_Idle_01.fbxANIM_CharacterBase_Standing_TurnRight_01.fbxANIM_CharacterBase_Standing_TurnLeft_01.fbxANIM_CharacterBase_Standing_WalkForward_01.fbxANIM_CharacterBase_Standing_WalkRight_01.fbxANIM_CharacterBase_Standing_WalkLeft_01.fbxANIM_CharacterBase_Standing_WalkBack_01.fbxANIM_CharacterBase_Standing_RunForward_01.fbxANIM_CharacterBase_Standing_RunRight_01.fbxANIM_CharacterBase_Standing_RunLeft_01.fbxANIM_CharacterBase_Standing_RunBack_01.fbxANIM_CharacterBase_Standing_Jump_01.fbxANIM_CharacterBase_Standing_Fall_01.fbxANIM_CharacterBase_Standing_LandLight_01.fbxANIM_CharacterBase_Standing_LandHard_01.fbxANIM_CharacterBase_Standing_Damege_01.fbxANIM_CharacterBase_Standing_Death_01.fbxANIM_CharacterBase_Crouch_Idle_01.fbxANIM_CharacterBase_Crouch_TurnRight_01.fbxANIM_CharacterBase_Croucg_TurnLeft_01.fbxANIM_CharacterBase_Crouch_WalkForward_01.fbxANIM_CharacterBase_Crouch_WalkRight_01.fbxANIM_CharacterBase_Crouch_WalkLeft_01.fbxANIM_CharacterBase_Crouch_WalkBack_01.fbxANIM_CharacterBase_Crouch_RunForward_01.fbxANIM_CharacterBase_Crouch_RunRight_01.fbxANIM_CharacterBase_Crouch_RunLeft_01.fbxANIM_CharacterBase_Crouch_RunBack_01.fbxANIM_CharacterBase_Crouch_Jump_01.fbxANIM_CharacterBase_Crouch_Fall_01.fbxANIM_CharacterBase_Crouch_LandLight_01.fbxANIM_CharacterBase_Crouch_LandHard_01.fbxANIM_CharacterBase_Crouch_Damege_01.fbxANIM_CharacterBase_Crouch_Death_01.fbx

2. Download QuadD_Example.zip from https://utdallas.app.box.com/folder/105401641160 and unzip it.

3. Remove all the files in Unity_QuadDCharAnimDemo_Example -> Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase and copy the FBX files that you created in Step 1 and your character’s texture maps into the folder.

4. Run Unity_QuadDCharAnimDemo_Example -> Assets -> QuadD -> Scenes -> Scn_AnimDemo.unity by clicking on the file name.

If you have Unity Hub, click on ADD, select Unity_QuadDCharAnimDemo_Example in the pop up window and click on Open. Select 2019.2.0f1 as Unity Version for the folder and click on the folder name. If you are asked “Are you sure you want to try to downgrade your project?” select CONFIRM.

Page 2: €¦ · Web viewSelect Rig_CharacterBase_Standing_Idle_02.fbx. Having Rig_CharacterBase_Standing_Idle_02.fbx in Inspector (the right side of the Unity window), Open Model tab, select

5. It may take a few minutes to import all the assets. Open Scenes folder in Assets -> QuadD. Click on Scn_AnimDemo. You should see a naked character standing in an environment and a menu with Return to Game, Save, Load, etc. next to the character (See screen capture below). If the menu is not there, right-click on Scn_MenusManagers in Assets -> QuadD -> Scenes, and select Open Scene Additive. The menu should pop up. When you play the scene, you can move the naked guy (not your character yet) around in the scene with the keyboard and mouse. To get out of the play mode, use the escape key.

In the next few steps you will prepare a rig by replacing the existing rig with a new one made from a standing idle animation:6. In Project (the left lower side of Unity window), open Assets -> QuadD -> Resources -> Animation ->

Characters -> CharacterBase folder, duplicate (Cmd+D) ANIM_CharacterBase_Standing_Idle_01.fbx. Rename the copy as Rig_CharacterBase_Standing_Idle_02.fbx.

7. Select Rig_CharacterBase_Standing_Idle_02.fbx. Having Rig_CharacterBase_Standing_Idle_02.fbx in Inspector (the right side of the Unity window), Open Model tab, select Import as Normals under Geometry, and click on Apply. Open Rig tab, select Humanoid as Animation Type, and click on Apply. Open Animation tab, deselect Import Animation, and click on Apply. Open Materials tab, select Import Materials, select Use External Materials (Legacy) as Location, and click

on Apply.

8. In Hierarchy (the upper left corner of Unity window), open Scene_AnimDemo -> Pf_CharacterTemplate01 -> Pf_Rig_CharTemplate_01, and try to delete Rig_QuadD_CharTemplate_01 (which is at the bottom). You will see a message “Cannot restructure Prehab instance.” Click on Open Prefab in a pop-up window and then delete Rig_QuadD_CharTemplate_01 in Hierarchy. The naked character should disappear from Game view (or Scene view, whichever you are in.)

9. Drop Rig_CharacterBase_Standing_Idle_02.fbx into Pf_Rig_CharTemplate_01. Your character should show up in Game view (or Scene view). The character may be too small or too big. We will resize it later.

10. Select and have Pf_Rig_CharTemplate_01 in Inspector. In Project find Rig_CharacterBase_Standing_Idle_02 in Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase, open Rig_CharacterBase_Standing_Idle_02 by clicking on a small triangle in front of a file icon and the file name. You should see Rig_CharacterBase_standing_Idle_01Avatar with a right brown icon that looks sort of like a human torso. Drag the avatar (Rig_CharacterBase_standing_Idle_01Avatar) into Avatar under Animator in Pf_Rig_CharTemplate_01.

In the next few steps, you prepare your animation clips:

Page 3: €¦ · Web viewSelect Rig_CharacterBase_Standing_Idle_02.fbx. Having Rig_CharacterBase_Standing_Idle_02.fbx in Inspector (the right side of the Unity window), Open Model tab, select

11. If your character is too small or too big, select all fbx files in Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase, in Inspector select Model tab, increase or decrease Scale Factor until the character is roughly between 1 and 2 meters tall, and click Apply.

12. While all fbx files in Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase are still selected, select Rig tab, select Humanoid as Animation Type, and click Apply.

13. In Hierarchy, select Scn_AnimDemos -> Pf_CharacterTemplate01 -> Pf_Rig_CharTemplate_01. In Inspector, find Controller under Animator and click on . Select AnimCtrl_CharTemplate_01 (bottom one) in a pop-up window. In Inspector, double-click on AnimCtrl_CharTemplate_01.

14. You should be taken to Animator view in the upper middle part of the Unity window and see boxes (animations). Delete the orange box and all the gray boxes.

15. Select ANIM_CharacterBase_Standing_Idle_01 in Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase and drag it to Animator view where you still have three boxes. An orange box connected to the green box (“Entry”) shows up.

16. Drag everything but ANIM_CharacterBase_Standing_Idle_01 and Rig_CharacterBase_Standing_Idle_02 in Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase into Animator view. You should see a number of grey boxes appear. Go back to Game view.

17. In Hierarchy, select Scn_AnimDemos -> Pf_CharacterTemplate01 -> Pf_Rig_CharTemplate_01. In Inspector, check to see if AnimCtrl_CharTemplate_01 is still selected as Controller under Animator. If not, click on next to the box for the controller name. Select AnimCtrl_CharTemplate_01 (bottom one) in a pop-up window.

Page 4: €¦ · Web viewSelect Rig_CharacterBase_Standing_Idle_02.fbx. Having Rig_CharacterBase_Standing_Idle_02.fbx in Inspector (the right side of the Unity window), Open Model tab, select

18. When you play the scene, you can move your character around in the scene with the keyboard and mouse. To get out of the play mode, use the escape key.

19. If you need to clip an animation in an FBX file imported in Unity, select the file in Unity_QuadDCharAnimDemo_Example -> Assets -> QuadD -> Resources -> Animation -> Characters -> CharacterBase. Inspector with a timeline should shows up and you can clip the animation by changing the starting frame and ending frame.

20. If your character floats above the floor, in Hierarchy, select Scn_AnimDemos -> Pf_CharacterTemplate01 -> Pf_Rig_CharTemplate_01 -> Rig_CharacterBase_Standing_Idle_02.fbx, In Inspector, adjust the Y-coordinate of Position under Transform so that the character’s feet reach the floor.

Notes: To detach a camera from the character, in Hierarchy find Cam Script CAM_Player

(QuadD_Player_Camera) under Quad D_Actor Info (Script) in Scn_AnimDemo -> Pf_CharacterTemplate 01, click on , select None in a popup window.

To reattach a camera to the character, in Hierarchy find Scn_AnimDemo -> PF_PlayerCamRig -> Loc_VertRotator -> Loc_HorzRotator -> CAM_Player, find Cam Script under Quad D_Actor Info (Script) in Scn_AnimDemo -> Pf_CharacterTemplate 01, drag CAM_Player to Cam Script.