class_spriteframes.rst 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the SpriteFrames.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_SpriteFrames:
  5. SpriteFrames
  6. ============
  7. **Inherits:** :ref:`Resource<class_resource>` **<** :ref:`Reference<class_reference>` **<** :ref:`Object<class_object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Sprite frame library for AnimatedSprite.
  12. Member Functions
  13. ----------------
  14. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  15. | void | :ref:`add_animation<class_SpriteFrames_add_animation>` **(** :ref:`String<class_string>` anim **)** |
  16. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  17. | void | :ref:`add_frame<class_SpriteFrames_add_frame>` **(** :ref:`String<class_string>` anim, :ref:`Texture<class_texture>` frame, :ref:`int<class_int>` at_position=-1 **)** |
  18. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  19. | void | :ref:`clear<class_SpriteFrames_clear>` **(** :ref:`String<class_string>` anim **)** |
  20. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  21. | void | :ref:`clear_all<class_SpriteFrames_clear_all>` **(** **)** |
  22. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  23. | :ref:`bool<class_bool>` | :ref:`get_animation_loop<class_SpriteFrames_get_animation_loop>` **(** :ref:`String<class_string>` anim **)** const |
  24. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  25. | :ref:`float<class_float>` | :ref:`get_animation_speed<class_SpriteFrames_get_animation_speed>` **(** :ref:`String<class_string>` anim **)** const |
  26. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  27. | :ref:`Texture<class_texture>` | :ref:`get_frame<class_SpriteFrames_get_frame>` **(** :ref:`String<class_string>` anim, :ref:`int<class_int>` idx **)** const |
  28. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  29. | :ref:`int<class_int>` | :ref:`get_frame_count<class_SpriteFrames_get_frame_count>` **(** :ref:`String<class_string>` anim **)** const |
  30. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  31. | :ref:`bool<class_bool>` | :ref:`has_animation<class_SpriteFrames_has_animation>` **(** :ref:`String<class_string>` anim **)** const |
  32. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  33. | void | :ref:`remove_animation<class_SpriteFrames_remove_animation>` **(** :ref:`String<class_string>` anim **)** |
  34. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  35. | void | :ref:`remove_frame<class_SpriteFrames_remove_frame>` **(** :ref:`String<class_string>` anim, :ref:`int<class_int>` idx **)** |
  36. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  37. | void | :ref:`rename_animation<class_SpriteFrames_rename_animation>` **(** :ref:`String<class_string>` anim, :ref:`String<class_string>` newname **)** |
  38. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  39. | void | :ref:`set_animation_loop<class_SpriteFrames_set_animation_loop>` **(** :ref:`String<class_string>` anim, :ref:`bool<class_bool>` loop **)** |
  40. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  41. | void | :ref:`set_animation_speed<class_SpriteFrames_set_animation_speed>` **(** :ref:`String<class_string>` anim, :ref:`float<class_float>` speed **)** |
  42. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  43. | void | :ref:`set_frame<class_SpriteFrames_set_frame>` **(** :ref:`String<class_string>` anim, :ref:`int<class_int>` idx, :ref:`Texture<class_texture>` txt **)** |
  44. +--------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  45. Member Variables
  46. ----------------
  47. - :ref:`Array<class_array>` **animations**
  48. - :ref:`Array<class_array>` **frames**
  49. Description
  50. -----------
  51. Sprite frame library for :ref:`AnimatedSprite<class_animatedsprite>`.
  52. Member Function Description
  53. ---------------------------
  54. .. _class_SpriteFrames_add_animation:
  55. - void **add_animation** **(** :ref:`String<class_string>` anim **)**
  56. .. _class_SpriteFrames_add_frame:
  57. - void **add_frame** **(** :ref:`String<class_string>` anim, :ref:`Texture<class_texture>` frame, :ref:`int<class_int>` at_position=-1 **)**
  58. .. _class_SpriteFrames_clear:
  59. - void **clear** **(** :ref:`String<class_string>` anim **)**
  60. .. _class_SpriteFrames_clear_all:
  61. - void **clear_all** **(** **)**
  62. .. _class_SpriteFrames_get_animation_loop:
  63. - :ref:`bool<class_bool>` **get_animation_loop** **(** :ref:`String<class_string>` anim **)** const
  64. .. _class_SpriteFrames_get_animation_speed:
  65. - :ref:`float<class_float>` **get_animation_speed** **(** :ref:`String<class_string>` anim **)** const
  66. .. _class_SpriteFrames_get_frame:
  67. - :ref:`Texture<class_texture>` **get_frame** **(** :ref:`String<class_string>` anim, :ref:`int<class_int>` idx **)** const
  68. .. _class_SpriteFrames_get_frame_count:
  69. - :ref:`int<class_int>` **get_frame_count** **(** :ref:`String<class_string>` anim **)** const
  70. .. _class_SpriteFrames_has_animation:
  71. - :ref:`bool<class_bool>` **has_animation** **(** :ref:`String<class_string>` anim **)** const
  72. .. _class_SpriteFrames_remove_animation:
  73. - void **remove_animation** **(** :ref:`String<class_string>` anim **)**
  74. .. _class_SpriteFrames_remove_frame:
  75. - void **remove_frame** **(** :ref:`String<class_string>` anim, :ref:`int<class_int>` idx **)**
  76. .. _class_SpriteFrames_rename_animation:
  77. - void **rename_animation** **(** :ref:`String<class_string>` anim, :ref:`String<class_string>` newname **)**
  78. .. _class_SpriteFrames_set_animation_loop:
  79. - void **set_animation_loop** **(** :ref:`String<class_string>` anim, :ref:`bool<class_bool>` loop **)**
  80. .. _class_SpriteFrames_set_animation_speed:
  81. - void **set_animation_speed** **(** :ref:`String<class_string>` anim, :ref:`float<class_float>` speed **)**
  82. .. _class_SpriteFrames_set_frame:
  83. - void **set_frame** **(** :ref:`String<class_string>` anim, :ref:`int<class_int>` idx, :ref:`Texture<class_texture>` txt **)**