class_visualscriptpropertyget.rst 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222
  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/3.6/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/3.6/modules/visual_script/doc_classes/VisualScriptPropertyGet.xml.
  6. .. _class_VisualScriptPropertyGet:
  7. VisualScriptPropertyGet
  8. =======================
  9. **Inherits:** :ref:`VisualScriptNode<class_VisualScriptNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
  10. A Visual Script node returning a value of a property from an :ref:`Object<class_Object>`.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. **VisualScriptPropertyGet** can return a value of any property from the current object or other objects.
  15. .. rst-class:: classref-reftable-group
  16. Properties
  17. ----------
  18. .. table::
  19. :widths: auto
  20. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  21. | :ref:`String<class_String>` | :ref:`base_script<class_VisualScriptPropertyGet_property_base_script>` | |
  22. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  23. | :ref:`String<class_String>` | :ref:`base_type<class_VisualScriptPropertyGet_property_base_type>` | ``"Object"`` |
  24. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  25. | :ref:`Variant.Type<enum_@GlobalScope_Variant.Type>` | :ref:`basic_type<class_VisualScriptPropertyGet_property_basic_type>` | |
  26. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  27. | :ref:`String<class_String>` | :ref:`index<class_VisualScriptPropertyGet_property_index>` | |
  28. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  29. | :ref:`NodePath<class_NodePath>` | :ref:`node_path<class_VisualScriptPropertyGet_property_node_path>` | |
  30. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  31. | :ref:`String<class_String>` | :ref:`property<class_VisualScriptPropertyGet_property_property>` | ``""`` |
  32. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  33. | :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` | :ref:`set_mode<class_VisualScriptPropertyGet_property_set_mode>` | ``0`` |
  34. +--------------------------------------------------------+------------------------------------------------------------------------+--------------+
  35. .. rst-class:: classref-section-separator
  36. ----
  37. .. rst-class:: classref-descriptions-group
  38. Enumerations
  39. ------------
  40. .. _enum_VisualScriptPropertyGet_CallMode:
  41. .. rst-class:: classref-enumeration
  42. enum **CallMode**:
  43. .. _class_VisualScriptPropertyGet_constant_CALL_MODE_SELF:
  44. .. rst-class:: classref-enumeration-constant
  45. :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` **CALL_MODE_SELF** = ``0``
  46. The property will be retrieved from this :ref:`Object<class_Object>`.
  47. .. _class_VisualScriptPropertyGet_constant_CALL_MODE_NODE_PATH:
  48. .. rst-class:: classref-enumeration-constant
  49. :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` **CALL_MODE_NODE_PATH** = ``1``
  50. The property will be retrieved from the given :ref:`Node<class_Node>` in the scene tree.
  51. .. _class_VisualScriptPropertyGet_constant_CALL_MODE_INSTANCE:
  52. .. rst-class:: classref-enumeration-constant
  53. :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` **CALL_MODE_INSTANCE** = ``2``
  54. The property will be retrieved from an instanced node with the given type and script.
  55. .. _class_VisualScriptPropertyGet_constant_CALL_MODE_BASIC_TYPE:
  56. .. rst-class:: classref-enumeration-constant
  57. :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` **CALL_MODE_BASIC_TYPE** = ``3``
  58. The property will be retrieved from a GDScript basic type (e.g. :ref:`Vector2<class_Vector2>`).
  59. .. rst-class:: classref-section-separator
  60. ----
  61. .. rst-class:: classref-descriptions-group
  62. Property Descriptions
  63. ---------------------
  64. .. _class_VisualScriptPropertyGet_property_base_script:
  65. .. rst-class:: classref-property
  66. :ref:`String<class_String>` **base_script**
  67. .. rst-class:: classref-property-setget
  68. - void **set_base_script** **(** :ref:`String<class_String>` value **)**
  69. - :ref:`String<class_String>` **get_base_script** **(** **)**
  70. The script to be used when :ref:`set_mode<class_VisualScriptPropertyGet_property_set_mode>` is set to :ref:`CALL_MODE_INSTANCE<class_VisualScriptPropertyGet_constant_CALL_MODE_INSTANCE>`.
  71. .. rst-class:: classref-item-separator
  72. ----
  73. .. _class_VisualScriptPropertyGet_property_base_type:
  74. .. rst-class:: classref-property
  75. :ref:`String<class_String>` **base_type** = ``"Object"``
  76. .. rst-class:: classref-property-setget
  77. - void **set_base_type** **(** :ref:`String<class_String>` value **)**
  78. - :ref:`String<class_String>` **get_base_type** **(** **)**
  79. The base type to be used when :ref:`set_mode<class_VisualScriptPropertyGet_property_set_mode>` is set to :ref:`CALL_MODE_INSTANCE<class_VisualScriptPropertyGet_constant_CALL_MODE_INSTANCE>`.
  80. .. rst-class:: classref-item-separator
  81. ----
  82. .. _class_VisualScriptPropertyGet_property_basic_type:
  83. .. rst-class:: classref-property
  84. :ref:`Variant.Type<enum_@GlobalScope_Variant.Type>` **basic_type**
  85. .. rst-class:: classref-property-setget
  86. - void **set_basic_type** **(** :ref:`Variant.Type<enum_@GlobalScope_Variant.Type>` value **)**
  87. - :ref:`Variant.Type<enum_@GlobalScope_Variant.Type>` **get_basic_type** **(** **)**
  88. The type to be used when :ref:`set_mode<class_VisualScriptPropertyGet_property_set_mode>` is set to :ref:`CALL_MODE_BASIC_TYPE<class_VisualScriptPropertyGet_constant_CALL_MODE_BASIC_TYPE>`.
  89. .. rst-class:: classref-item-separator
  90. ----
  91. .. _class_VisualScriptPropertyGet_property_index:
  92. .. rst-class:: classref-property
  93. :ref:`String<class_String>` **index**
  94. .. rst-class:: classref-property-setget
  95. - void **set_index** **(** :ref:`String<class_String>` value **)**
  96. - :ref:`String<class_String>` **get_index** **(** **)**
  97. The indexed name of the property to retrieve. See :ref:`Object.get_indexed<class_Object_method_get_indexed>` for details.
  98. .. rst-class:: classref-item-separator
  99. ----
  100. .. _class_VisualScriptPropertyGet_property_node_path:
  101. .. rst-class:: classref-property
  102. :ref:`NodePath<class_NodePath>` **node_path**
  103. .. rst-class:: classref-property-setget
  104. - void **set_base_path** **(** :ref:`NodePath<class_NodePath>` value **)**
  105. - :ref:`NodePath<class_NodePath>` **get_base_path** **(** **)**
  106. The node path to use when :ref:`set_mode<class_VisualScriptPropertyGet_property_set_mode>` is set to :ref:`CALL_MODE_NODE_PATH<class_VisualScriptPropertyGet_constant_CALL_MODE_NODE_PATH>`.
  107. .. rst-class:: classref-item-separator
  108. ----
  109. .. _class_VisualScriptPropertyGet_property_property:
  110. .. rst-class:: classref-property
  111. :ref:`String<class_String>` **property** = ``""``
  112. .. rst-class:: classref-property-setget
  113. - void **set_property** **(** :ref:`String<class_String>` value **)**
  114. - :ref:`String<class_String>` **get_property** **(** **)**
  115. The name of the property to retrieve. Changing this will clear :ref:`index<class_VisualScriptPropertyGet_property_index>`.
  116. .. rst-class:: classref-item-separator
  117. ----
  118. .. _class_VisualScriptPropertyGet_property_set_mode:
  119. .. rst-class:: classref-property
  120. :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` **set_mode** = ``0``
  121. .. rst-class:: classref-property-setget
  122. - void **set_call_mode** **(** :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` value **)**
  123. - :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` **get_call_mode** **(** **)**
  124. ``set_mode`` determines the target object from which the property will be retrieved. See :ref:`CallMode<enum_VisualScriptPropertyGet_CallMode>` for options.
  125. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  126. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  127. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  128. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`