class_animationnodeoneshot.rst 8.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238
  1. :github_url: hide
  2. .. DO NOT EDIT THIS FILE!!!
  3. .. Generated automatically from Godot engine sources.
  4. .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/AnimationNodeOneShot.xml.
  6. .. _class_AnimationNodeOneShot:
  7. AnimationNodeOneShot
  8. ====================
  9. **Inherits:** :ref:`AnimationNodeSync<class_AnimationNodeSync>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
  10. Plays an animation once in :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. A resource to add to an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. This node will execute a sub-animation and return once it finishes. Blend times for fading in and out can be customized, as well as filters.
  15. .. rst-class:: classref-introduction-group
  16. Tutorials
  17. ---------
  18. - :doc:`AnimationTree <../tutorials/animation/animation_tree>`
  19. - `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
  20. .. rst-class:: classref-reftable-group
  21. Properties
  22. ----------
  23. .. table::
  24. :widths: auto
  25. +---------------------------------------------------+-----------------------------------------------------------------------------------------------+-----------+
  26. | :ref:`bool<class_bool>` | :ref:`autorestart<class_AnimationNodeOneShot_property_autorestart>` | ``false`` |
  27. +---------------------------------------------------+-----------------------------------------------------------------------------------------------+-----------+
  28. | :ref:`float<class_float>` | :ref:`autorestart_delay<class_AnimationNodeOneShot_property_autorestart_delay>` | ``1.0`` |
  29. +---------------------------------------------------+-----------------------------------------------------------------------------------------------+-----------+
  30. | :ref:`float<class_float>` | :ref:`autorestart_random_delay<class_AnimationNodeOneShot_property_autorestart_random_delay>` | ``0.0`` |
  31. +---------------------------------------------------+-----------------------------------------------------------------------------------------------+-----------+
  32. | :ref:`float<class_float>` | :ref:`fadein_time<class_AnimationNodeOneShot_property_fadein_time>` | ``0.0`` |
  33. +---------------------------------------------------+-----------------------------------------------------------------------------------------------+-----------+
  34. | :ref:`float<class_float>` | :ref:`fadeout_time<class_AnimationNodeOneShot_property_fadeout_time>` | ``0.0`` |
  35. +---------------------------------------------------+-----------------------------------------------------------------------------------------------+-----------+
  36. | :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` | :ref:`mix_mode<class_AnimationNodeOneShot_property_mix_mode>` | ``0`` |
  37. +---------------------------------------------------+-----------------------------------------------------------------------------------------------+-----------+
  38. .. rst-class:: classref-section-separator
  39. ----
  40. .. rst-class:: classref-descriptions-group
  41. Enumerations
  42. ------------
  43. .. _enum_AnimationNodeOneShot_OneShotRequest:
  44. .. rst-class:: classref-enumeration
  45. enum **OneShotRequest**:
  46. .. _class_AnimationNodeOneShot_constant_ONE_SHOT_REQUEST_NONE:
  47. .. rst-class:: classref-enumeration-constant
  48. :ref:`OneShotRequest<enum_AnimationNodeOneShot_OneShotRequest>` **ONE_SHOT_REQUEST_NONE** = ``0``
  49. .. _class_AnimationNodeOneShot_constant_ONE_SHOT_REQUEST_FIRE:
  50. .. rst-class:: classref-enumeration-constant
  51. :ref:`OneShotRequest<enum_AnimationNodeOneShot_OneShotRequest>` **ONE_SHOT_REQUEST_FIRE** = ``1``
  52. .. _class_AnimationNodeOneShot_constant_ONE_SHOT_REQUEST_ABORT:
  53. .. rst-class:: classref-enumeration-constant
  54. :ref:`OneShotRequest<enum_AnimationNodeOneShot_OneShotRequest>` **ONE_SHOT_REQUEST_ABORT** = ``2``
  55. .. rst-class:: classref-item-separator
  56. ----
  57. .. _enum_AnimationNodeOneShot_MixMode:
  58. .. rst-class:: classref-enumeration
  59. enum **MixMode**:
  60. .. _class_AnimationNodeOneShot_constant_MIX_MODE_BLEND:
  61. .. rst-class:: classref-enumeration-constant
  62. :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` **MIX_MODE_BLEND** = ``0``
  63. .. _class_AnimationNodeOneShot_constant_MIX_MODE_ADD:
  64. .. rst-class:: classref-enumeration-constant
  65. :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` **MIX_MODE_ADD** = ``1``
  66. .. rst-class:: classref-section-separator
  67. ----
  68. .. rst-class:: classref-descriptions-group
  69. Property Descriptions
  70. ---------------------
  71. .. _class_AnimationNodeOneShot_property_autorestart:
  72. .. rst-class:: classref-property
  73. :ref:`bool<class_bool>` **autorestart** = ``false``
  74. .. rst-class:: classref-property-setget
  75. - void **set_autorestart** **(** :ref:`bool<class_bool>` value **)**
  76. - :ref:`bool<class_bool>` **has_autorestart** **(** **)**
  77. If ``true``, the sub-animation will restart automatically after finishing.
  78. .. rst-class:: classref-item-separator
  79. ----
  80. .. _class_AnimationNodeOneShot_property_autorestart_delay:
  81. .. rst-class:: classref-property
  82. :ref:`float<class_float>` **autorestart_delay** = ``1.0``
  83. .. rst-class:: classref-property-setget
  84. - void **set_autorestart_delay** **(** :ref:`float<class_float>` value **)**
  85. - :ref:`float<class_float>` **get_autorestart_delay** **(** **)**
  86. The delay after which the automatic restart is triggered, in seconds.
  87. .. rst-class:: classref-item-separator
  88. ----
  89. .. _class_AnimationNodeOneShot_property_autorestart_random_delay:
  90. .. rst-class:: classref-property
  91. :ref:`float<class_float>` **autorestart_random_delay** = ``0.0``
  92. .. rst-class:: classref-property-setget
  93. - void **set_autorestart_random_delay** **(** :ref:`float<class_float>` value **)**
  94. - :ref:`float<class_float>` **get_autorestart_random_delay** **(** **)**
  95. If :ref:`autorestart<class_AnimationNodeOneShot_property_autorestart>` is ``true``, a random additional delay (in seconds) between 0 and this value will be added to :ref:`autorestart_delay<class_AnimationNodeOneShot_property_autorestart_delay>`.
  96. .. rst-class:: classref-item-separator
  97. ----
  98. .. _class_AnimationNodeOneShot_property_fadein_time:
  99. .. rst-class:: classref-property
  100. :ref:`float<class_float>` **fadein_time** = ``0.0``
  101. .. rst-class:: classref-property-setget
  102. - void **set_fadein_time** **(** :ref:`float<class_float>` value **)**
  103. - :ref:`float<class_float>` **get_fadein_time** **(** **)**
  104. .. container:: contribute
  105. There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
  106. .. rst-class:: classref-item-separator
  107. ----
  108. .. _class_AnimationNodeOneShot_property_fadeout_time:
  109. .. rst-class:: classref-property
  110. :ref:`float<class_float>` **fadeout_time** = ``0.0``
  111. .. rst-class:: classref-property-setget
  112. - void **set_fadeout_time** **(** :ref:`float<class_float>` value **)**
  113. - :ref:`float<class_float>` **get_fadeout_time** **(** **)**
  114. .. container:: contribute
  115. There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
  116. .. rst-class:: classref-item-separator
  117. ----
  118. .. _class_AnimationNodeOneShot_property_mix_mode:
  119. .. rst-class:: classref-property
  120. :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` **mix_mode** = ``0``
  121. .. rst-class:: classref-property-setget
  122. - void **set_mix_mode** **(** :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` value **)**
  123. - :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` **get_mix_mode** **(** **)**
  124. .. container:: contribute
  125. There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
  126. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  127. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  128. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  129. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  130. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  131. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`