animation.rst 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. Animation
  2. =========
  3. Animation supported:
  4. - transform animation of all types of objects
  5. - transform animation of pose bones
  6. - shape key animation
  7. - light animation
  8. - camera animation
  9. Multiple Actions For Single Object
  10. ----------------------------------
  11. In most games, one objects would have serveral animations to switch between.
  12. This addon have a support for exporting multiple actions all at once into
  13. a single AnimationPlayer and makes it easy to switch actions.
  14. This worksflow makes use of blender nla_tracks. Here is a brief guide of how
  15. to use this feature:
  16. **1. Switch workspace to 'Dope Sheet'**
  17. .. image:: img/dope_sheet.jpg
  18. **2. Stash the active action**
  19. the stashed action while not action would still be exported
  20. .. image:: img/stash_action.jpg
  21. **3. Check stashed actions in 'NLA Editor' [optional]**
  22. Switch workspace to 'NLA Editor'
  23. .. image:: img/nla_editor.jpg
  24. Make sure all stashed actions are muted
  25. .. image:: img/nla_strip.jpg
  26. **4. Export the scene**
  27. all the stashed action as well as the active action are exported
  28. to the an AnimationPlayer
  29. .. image:: img/in_godot.jpg
  30. Constraints
  31. -----------
  32. Sometimes complicated animation is built with object constraint, an usual
  33. example is inverse kinematics. The addon would automatically check if an
  34. object has some constraint, if it does, all the constraints are baked into
  35. every action the object has and then exported.
  36. Animation Mode
  37. ---------------------------
  38. Godot and Blender have different structure to store animation data.
  39. In Godot animation data is stored in an AnimationPlayer node, instead
  40. of in each animated node. In order to fix this inconsistence and still
  41. make the animation play versatile, this addon has three aimation exporting
  42. modes.
  43. **Mode 'Animation as Actions'**
  44. Treat all the animation as object actions, so in the exported scene, every
  45. object would have its own AnimationPlayer and hold its actions.
  46. **Mode 'Scene Animation'**
  47. If you want your animation generate same result as playing at Blender's
  48. timeline, this is what you want. In this mode, all the animation in the scene
  49. are placed in just one AnimationPlayer in the scene root.
  50. **Mode 'Animation as Action with Squash'**
  51. This mode has very similar behaviour of mode 'Animation as Action', but it
  52. can generate less AnimationPlayers, objects in parent-children relation would
  53. share their AnimationPlayer. It is useful when you have several rigs, and each
  54. Skeleton and Mesh has actions, then one rig would have just one AnimationPlayer.