AnimationNodeStateMachinePlayback.xml 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="AnimationNodeStateMachinePlayback" inherits="Resource" category="Core" version="3.1.2">
  3. <brief_description>
  4. Playback control for AnimationNodeStateMachine.
  5. </brief_description>
  6. <description>
  7. Allows control of [AnimationTree] state machines created with [AnimationNodeStateMachine]. Retrieve with [code]$AnimationTree.get("parameters/playback")[/code]. Example:
  8. [codeblock]
  9. var state_machine = $AnimationTree.get("parameters/playback")
  10. state_machine.travel("some_state")
  11. [/codeblock]
  12. </description>
  13. <tutorials>
  14. </tutorials>
  15. <methods>
  16. <method name="get_current_node" qualifiers="const">
  17. <return type="String">
  18. </return>
  19. <description>
  20. Returns the currently playing animation state.
  21. </description>
  22. </method>
  23. <method name="get_travel_path" qualifiers="const">
  24. <return type="PoolStringArray">
  25. </return>
  26. <description>
  27. </description>
  28. </method>
  29. <method name="is_playing" qualifiers="const">
  30. <return type="bool">
  31. </return>
  32. <description>
  33. Returns [code]true[/code] if an animation is playing.
  34. </description>
  35. </method>
  36. <method name="start">
  37. <return type="void">
  38. </return>
  39. <argument index="0" name="node" type="String">
  40. </argument>
  41. <description>
  42. Starts playing the given animation.
  43. </description>
  44. </method>
  45. <method name="stop">
  46. <return type="void">
  47. </return>
  48. <description>
  49. Stops the currently playing animation.
  50. </description>
  51. </method>
  52. <method name="travel">
  53. <return type="void">
  54. </return>
  55. <argument index="0" name="to_node" type="String">
  56. </argument>
  57. <description>
  58. Transitions from the current state to another one, following the shortest path.
  59. </description>
  60. </method>
  61. </methods>
  62. <constants>
  63. </constants>
  64. </class>