diff --git a/classes/class_@gdscript.rst b/classes/class_@gdscript.rst index 5c4841a37..2f4517510 100644 --- a/classes/class_@gdscript.rst +++ b/classes/class_@gdscript.rst @@ -1149,7 +1149,12 @@ Returns the position of the first non-zero digit, after the decimal point. Note - :ref:`float` **stepify** **(** :ref:`float` s, :ref:`float` step **)** -Snaps float value ``s`` to a given ``step``. +Snaps float value ``s`` to a given ``step``. This can also be used to round a floating point number to an arbitrary number of decimals. + +:: + + stepify(100, 32) # Returns 96 + stepify(3.14159, 0.01) # Returns 3.14 .. _class_@GDScript_method_str: diff --git a/classes/class_astar.rst b/classes/class_astar.rst index e6763eba8..df7d2506b 100644 --- a/classes/class_astar.rst +++ b/classes/class_astar.rst @@ -44,8 +44,12 @@ Methods +-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolIntArray` | :ref:`get_id_path` **(** :ref:`int` from_id, :ref:`int` to_id **)** | +-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`get_point_capacity` **(** **)** const | ++-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolIntArray` | :ref:`get_point_connections` **(** :ref:`int` id **)** | +-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`get_point_count` **(** **)** const | ++-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolVector3Array` | :ref:`get_point_path` **(** :ref:`int` from_id, :ref:`int` to_id **)** | +-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`get_point_position` **(** :ref:`int` id **)** const | @@ -60,6 +64,8 @@ Methods +-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`remove_point` **(** :ref:`int` id **)** | +-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`reserve_space` **(** :ref:`int` num_nodes **)** | ++-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_point_disabled` **(** :ref:`int` id, :ref:`bool` disabled=true **)** | +-------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_point_position` **(** :ref:`int` id, :ref:`Vector3` position **)** | @@ -184,6 +190,12 @@ Returns an array with the IDs of the points that form the path found by AStar be If you change the 2nd point's weight to 3, then the result will be ``[1, 4, 3]`` instead, because now even though the distance is longer, it's "easier" to get through point 4 than through point 2. +.. _class_AStar_method_get_point_capacity: + +- :ref:`int` **get_point_capacity** **(** **)** const + +Returns the capacity of the structure backing the points, useful in conjunction with ``reserve_space``. + .. _class_AStar_method_get_point_connections: - :ref:`PoolIntArray` **get_point_connections** **(** :ref:`int` id **)** @@ -203,6 +215,12 @@ Returns an array with the IDs of the points that form the connection with the gi var neighbors = astar.get_point_connections(1) # Returns [2, 3] +.. _class_AStar_method_get_point_count: + +- :ref:`int` **get_point_count** **(** **)** const + +Returns the number of points currently in the points pool. + .. _class_AStar_method_get_point_path: - :ref:`PoolVector3Array` **get_point_path** **(** :ref:`int` from_id, :ref:`int` to_id **)** @@ -245,6 +263,12 @@ Returns whether a point is disabled or not for pathfinding. By default, all poin Removes the point associated with the given ``id`` from the points pool. +.. _class_AStar_method_reserve_space: + +- void **reserve_space** **(** :ref:`int` num_nodes **)** + +Reserves space internally for ``num_nodes`` points, useful if you're adding a known large number of points at once, for a grid for instance. New capacity must be greater or equals to old capacity. + .. _class_AStar_method_set_point_disabled: - void **set_point_disabled** **(** :ref:`int` id, :ref:`bool` disabled=true **)** diff --git a/classes/class_astar2d.rst b/classes/class_astar2d.rst index e92bcef51..5828a1550 100644 --- a/classes/class_astar2d.rst +++ b/classes/class_astar2d.rst @@ -40,8 +40,12 @@ Methods +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolIntArray` | :ref:`get_id_path` **(** :ref:`int` from_id, :ref:`int` to_id **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`get_point_capacity` **(** **)** const | ++-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolIntArray` | :ref:`get_point_connections` **(** :ref:`int` id **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`get_point_count` **(** **)** const | ++-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolVector2Array` | :ref:`get_point_path` **(** :ref:`int` from_id, :ref:`int` to_id **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`get_point_position` **(** :ref:`int` id **)** const | @@ -56,6 +60,8 @@ Methods +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`remove_point` **(** :ref:`int` id **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`reserve_space` **(** :ref:`int` num_nodes **)** | ++-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_point_disabled` **(** :ref:`int` id, :ref:`bool` disabled=true **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_point_position` **(** :ref:`int` id, :ref:`Vector2` position **)** | @@ -166,6 +172,12 @@ Returns an array with the IDs of the points that form the path found by AStar2D If you change the 2nd point's weight to 3, then the result will be ``[1, 4, 3]`` instead, because now even though the distance is longer, it's "easier" to get through point 4 than through point 2. +.. _class_AStar2D_method_get_point_capacity: + +- :ref:`int` **get_point_capacity** **(** **)** const + +Returns the capacity of the structure backing the points, useful in conjunction with ``reserve_space``. + .. _class_AStar2D_method_get_point_connections: - :ref:`PoolIntArray` **get_point_connections** **(** :ref:`int` id **)** @@ -185,6 +197,12 @@ Returns an array with the IDs of the points that form the connection with the gi var neighbors = astar.get_point_connections(1) # Returns [2, 3] +.. _class_AStar2D_method_get_point_count: + +- :ref:`int` **get_point_count** **(** **)** const + +Returns the number of points currently in the points pool. + .. _class_AStar2D_method_get_point_path: - :ref:`PoolVector2Array` **get_point_path** **(** :ref:`int` from_id, :ref:`int` to_id **)** @@ -227,6 +245,12 @@ Returns whether a point is disabled or not for pathfinding. By default, all poin Removes the point associated with the given ``id`` from the points pool. +.. _class_AStar2D_method_reserve_space: + +- void **reserve_space** **(** :ref:`int` num_nodes **)** + +Reserves space internally for ``num_nodes`` points, useful if you're adding a known large number of points at once, for a grid for instance. New capacity must be greater or equals to old capacity. + .. _class_AStar2D_method_set_point_disabled: - void **set_point_disabled** **(** :ref:`int` id, :ref:`bool` disabled=true **)** diff --git a/classes/class_audiostreamgenerator.rst b/classes/class_audiostreamgenerator.rst index ff46b7390..de66a5963 100644 --- a/classes/class_audiostreamgenerator.rst +++ b/classes/class_audiostreamgenerator.rst @@ -27,6 +27,11 @@ Properties | :ref:`float` | :ref:`mix_rate` | 44100.0 | +---------------------------+-------------------------------------------------------------------------+---------+ +Tutorials +--------- + +- `https://github.com/godotengine/godot-demo-projects/tree/master/audio/generator `_ + Property Descriptions --------------------- diff --git a/classes/class_audiostreamgeneratorplayback.rst b/classes/class_audiostreamgeneratorplayback.rst index 052f3968c..8f05e5fc6 100644 --- a/classes/class_audiostreamgeneratorplayback.rst +++ b/classes/class_audiostreamgeneratorplayback.rst @@ -35,6 +35,11 @@ Methods | :ref:`bool` | :ref:`push_frame` **(** :ref:`Vector2` frame **)** | +-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+ +Tutorials +--------- + +- `https://github.com/godotengine/godot-demo-projects/tree/master/audio/generator `_ + Method Descriptions ------------------- diff --git a/classes/class_audiostreamsample.rst b/classes/class_audiostreamsample.rst index ec09c45d0..ce48255c4 100644 --- a/classes/class_audiostreamsample.rst +++ b/classes/class_audiostreamsample.rst @@ -107,6 +107,8 @@ Property Descriptions Contains the audio data in bytes. +**Note:** This property expects signed PCM8 data. To convert unsigned PCM8 to signed PCM8, subtract 128 from each byte. + .. _class_AudioStreamSample_property_format: - :ref:`Format` **format** diff --git a/classes/class_button.rst b/classes/class_button.rst index 27c2ca844..aeb7d1236 100644 --- a/classes/class_button.rst +++ b/classes/class_button.rst @@ -115,7 +115,7 @@ Text alignment policy for the button's text, use one of the ``ALIGN_*`` constant | *Getter* | get_clip_text() | +-----------+----------------------+ -When this property is enabled, text that is too large to fit the button is clipped, when disabled the Button will always be wide enough to hold the text. This property is disabled by default. +When this property is enabled, text that is too large to fit the button is clipped, when disabled the Button will always be wide enough to hold the text. .. _class_Button_property_flat: diff --git a/classes/class_control.rst b/classes/class_control.rst index 1ea334140..f35ecebde 100644 --- a/classes/class_control.rst +++ b/classes/class_control.rst @@ -133,7 +133,7 @@ Methods +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`CursorShape` | :ref:`get_cursor_shape` **(** :ref:`Vector2` position=Vector2( 0, 0 ) **)** const | +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Object` | :ref:`get_drag_data` **(** :ref:`Vector2` position **)** virtual | +| :ref:`Variant` | :ref:`get_drag_data` **(** :ref:`Vector2` position **)** virtual | +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`get_end` **(** **)** const | +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -1240,7 +1240,7 @@ Returns the mouse cursor shape the control displays on mouse hover. See :ref:`Cu .. _class_Control_method_get_drag_data: -- :ref:`Object` **get_drag_data** **(** :ref:`Vector2` position **)** virtual +- :ref:`Variant` **get_drag_data** **(** :ref:`Vector2` position **)** virtual Godot calls this method to get data that can be dragged and dropped onto controls that expect drop data. Returns ``null`` if there is no data to drag. Controls that want to receive drop data should implement :ref:`can_drop_data` and :ref:`drop_data`. ``position`` is local to this control. Drag may be forced with :ref:`force_drag`. diff --git a/classes/class_environment.rst b/classes/class_environment.rst index 4add15f47..82f07c9a3 100644 --- a/classes/class_environment.rst +++ b/classes/class_environment.rst @@ -96,7 +96,7 @@ Properties +--------------------------------------------------------+----------------------------------------------------------------------------------------------------+------------------------------------+ | :ref:`bool` | :ref:`fog_depth_enabled` | true | +--------------------------------------------------------+----------------------------------------------------------------------------------------------------+------------------------------------+ -| :ref:`float` | :ref:`fog_depth_end` | 0.0 | +| :ref:`float` | :ref:`fog_depth_end` | 100.0 | +--------------------------------------------------------+----------------------------------------------------------------------------------------------------+------------------------------------+ | :ref:`bool` | :ref:`fog_enabled` | false | +--------------------------------------------------------+----------------------------------------------------------------------------------------------------+------------------------------------+ @@ -873,13 +873,15 @@ Enables the fog depth. - :ref:`float` **fog_depth_end** +-----------+--------------------------+ -| *Default* | 0.0 | +| *Default* | 100.0 | +-----------+--------------------------+ | *Setter* | set_fog_depth_end(value) | +-----------+--------------------------+ | *Getter* | get_fog_depth_end() | +-----------+--------------------------+ +Fog's depth end distance from the camera. If this value is set to 0, it will be equal to the current camera's :ref:`Camera.far` value. + .. _class_Environment_property_fog_enabled: - :ref:`bool` **fog_enabled** @@ -892,7 +894,7 @@ Enables the fog depth. | *Getter* | is_fog_enabled() | +-----------+------------------------+ -Enables the fog. Needs fog_height_enabled and/or for_depth_enabled to actually display fog. +Enables the fog. Needs :ref:`fog_height_enabled` and/or :ref:`fog_depth_enabled` to actually display fog. .. _class_Environment_property_fog_height_curve: diff --git a/classes/class_gdscript.rst b/classes/class_gdscript.rst index 6a95e39a4..6498f770a 100644 --- a/classes/class_gdscript.rst +++ b/classes/class_gdscript.rst @@ -24,7 +24,7 @@ Methods +-------------------------------------------+-----------------------------------------------------------------------------------+ | :ref:`PoolByteArray` | :ref:`get_as_byte_code` **(** **)** const | +-------------------------------------------+-----------------------------------------------------------------------------------+ -| :ref:`Object` | :ref:`new` **(** ... **)** vararg | +| :ref:`Variant` | :ref:`new` **(** ... **)** vararg | +-------------------------------------------+-----------------------------------------------------------------------------------+ Description @@ -50,7 +50,7 @@ Returns byte code for the script source code. .. _class_GDScript_method_new: -- :ref:`Object` **new** **(** ... **)** vararg +- :ref:`Variant` **new** **(** ... **)** vararg Returns a new instance of the script. diff --git a/classes/class_geometry.rst b/classes/class_geometry.rst index df3a0ef0b..c9067f47e 100644 --- a/classes/class_geometry.rst +++ b/classes/class_geometry.rst @@ -56,6 +56,8 @@ Methods +-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Array` | :ref:`intersect_polyline_with_polygon_2d` **(** :ref:`PoolVector2Array` polyline, :ref:`PoolVector2Array` polygon **)** | +-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`bool` | :ref:`is_point_in_circle` **(** :ref:`Vector2` point, :ref:`Vector2` circle_position, :ref:`float` circle_radius **)** | ++-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`is_point_in_polygon` **(** :ref:`Vector2` point, :ref:`PoolVector2Array` polygon **)** | +-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`is_polygon_clockwise` **(** :ref:`PoolVector2Array` polygon **)** | @@ -86,8 +88,6 @@ Methods +-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Variant` | :ref:`segment_intersects_triangle` **(** :ref:`Vector3` from, :ref:`Vector3` to, :ref:`Vector3` a, :ref:`Vector3` b, :ref:`Vector3` c **)** | +-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`PoolVector2Array` | :ref:`transform_points_2d` **(** :ref:`PoolVector2Array` points, :ref:`Transform2D` transform **)** | -+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolIntArray` | :ref:`triangulate_delaunay_2d` **(** :ref:`PoolVector2Array` points **)** | +-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolIntArray` | :ref:`triangulate_polygon` **(** :ref:`PoolVector2Array` polygon **)** | @@ -265,6 +265,12 @@ The operation may result in an outer polygon (boundary) and inner polygon (hole) Intersects ``polyline`` with ``polygon`` and returns an array of intersected polylines. This performs :ref:`OPERATION_INTERSECTION` between the polyline and the polygon. This operation can be thought of as chopping a line with a closed shape. +.. _class_Geometry_method_is_point_in_circle: + +- :ref:`bool` **is_point_in_circle** **(** :ref:`Vector2` point, :ref:`Vector2` circle_position, :ref:`float` circle_radius **)** + +Returns ``true`` if ``point`` is inside the circle or if it's located exactly *on* the circle's boundary, otherwise returns ``false``. + .. _class_Geometry_method_is_point_in_polygon: - :ref:`bool` **is_point_in_polygon** **(** :ref:`Vector2` point, :ref:`PoolVector2Array` polygon **)** @@ -369,14 +375,6 @@ Checks if the segment (``from``, ``to``) intersects the sphere that is located a Tests if the segment (``from``, ``to``) intersects the triangle ``a``, ``b``, ``c``. If yes, returns the point of intersection as :ref:`Vector3`. If no intersection takes place, an empty :ref:`Variant` is returned. -.. _class_Geometry_method_transform_points_2d: - -- :ref:`PoolVector2Array` **transform_points_2d** **(** :ref:`PoolVector2Array` points, :ref:`Transform2D` transform **)** - -Transforms an array of points by ``transform`` and returns the result. - -Can be useful in conjunction with performing polygon boolean operations in a CSG-like manner, see :ref:`merge_polygons_2d`, :ref:`clip_polygons_2d`, :ref:`intersect_polygons_2d`, :ref:`exclude_polygons_2d`. - .. _class_Geometry_method_triangulate_delaunay_2d: - :ref:`PoolIntArray` **triangulate_delaunay_2d** **(** :ref:`PoolVector2Array` points **)** diff --git a/classes/class_graphnode.rst b/classes/class_graphnode.rst index 619395747..491576e83 100644 --- a/classes/class_graphnode.rst +++ b/classes/class_graphnode.rst @@ -106,6 +106,8 @@ Theme Properties +---------------------------------+---------------+---------------------+ | :ref:`Texture` | resizer | | +---------------------------------+---------------+---------------------+ +| :ref:`Color` | resizer_color | Color( 0, 0, 0, 1 ) | ++---------------------------------+---------------+---------------------+ | :ref:`StyleBox` | selectedframe | | +---------------------------------+---------------+---------------------+ | :ref:`int` | separation | 1 | diff --git a/classes/class_jsonrpc.rst b/classes/class_jsonrpc.rst new file mode 100644 index 000000000..8790e44a5 --- /dev/null +++ b/classes/class_jsonrpc.rst @@ -0,0 +1,97 @@ +:github_url: hide + +.. Generated automatically by doc/tools/makerst.py in Godot's source tree. +.. DO NOT EDIT THIS FILE, but the JSONRPC.xml source instead. +.. The source is found in doc/classes or modules//doc_classes. + +.. _class_JSONRPC: + +JSONRPC +======= + +**Inherits:** :ref:`Object` + +**Category:** Core + +Brief Description +----------------- + + + +Methods +------- + ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Dictionary` | :ref:`make_notification` **(** :ref:`String` method, :ref:`Variant` params **)** | ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Dictionary` | :ref:`make_request` **(** :ref:`String` method, :ref:`Variant` params, :ref:`Variant` id **)** | ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Dictionary` | :ref:`make_response` **(** :ref:`Variant` result, :ref:`Variant` id **)** | ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Dictionary` | :ref:`make_response_error` **(** :ref:`int` code, :ref:`String` message, :ref:`Variant` id=null **)** const | ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`process_action` **(** :ref:`Variant` action, :ref:`bool` recurse=false **)** | ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`String` | :ref:`process_string` **(** :ref:`String` action **)** | ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`set_scope` **(** :ref:`String` scope, :ref:`Object` target **)** | ++-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +Enumerations +------------ + +.. _enum_JSONRPC_ErrorCode: + +.. _class_JSONRPC_constant_PARSE_ERROR: + +.. _class_JSONRPC_constant_INVALID_REQUEST: + +.. _class_JSONRPC_constant_METHOD_NOT_FOUND: + +.. _class_JSONRPC_constant_INVALID_PARAMS: + +.. _class_JSONRPC_constant_INTERNAL_ERROR: + +enum **ErrorCode**: + +- **PARSE_ERROR** = **-32700** + +- **INVALID_REQUEST** = **-32600** + +- **METHOD_NOT_FOUND** = **-32601** + +- **INVALID_PARAMS** = **-32602** + +- **INTERNAL_ERROR** = **-32603** + +Method Descriptions +------------------- + +.. _class_JSONRPC_method_make_notification: + +- :ref:`Dictionary` **make_notification** **(** :ref:`String` method, :ref:`Variant` params **)** + +.. _class_JSONRPC_method_make_request: + +- :ref:`Dictionary` **make_request** **(** :ref:`String` method, :ref:`Variant` params, :ref:`Variant` id **)** + +.. _class_JSONRPC_method_make_response: + +- :ref:`Dictionary` **make_response** **(** :ref:`Variant` result, :ref:`Variant` id **)** + +.. _class_JSONRPC_method_make_response_error: + +- :ref:`Dictionary` **make_response_error** **(** :ref:`int` code, :ref:`String` message, :ref:`Variant` id=null **)** const + +.. _class_JSONRPC_method_process_action: + +- :ref:`Variant` **process_action** **(** :ref:`Variant` action, :ref:`bool` recurse=false **)** + +.. _class_JSONRPC_method_process_string: + +- :ref:`String` **process_string** **(** :ref:`String` action **)** + +.. _class_JSONRPC_method_set_scope: + +- void **set_scope** **(** :ref:`String` scope, :ref:`Object` target **)** + diff --git a/classes/class_mainloop.rst b/classes/class_mainloop.rst index b1b68fb76..aabb44407 100644 --- a/classes/class_mainloop.rst +++ b/classes/class_mainloop.rst @@ -28,6 +28,8 @@ Methods +-------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`_finalize` **(** **)** virtual | +-------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`_global_menu_action` **(** :ref:`Variant` id, :ref:`Variant` meta **)** virtual | ++-------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`_idle` **(** :ref:`float` delta **)** virtual | +-------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`_initialize` **(** **)** virtual | @@ -181,6 +183,10 @@ Called when files are dragged from the OS file manager and dropped in the game w Called before the program exits. +.. _class_MainLoop_method__global_menu_action: + +- void **_global_menu_action** **(** :ref:`Variant` id, :ref:`Variant` meta **)** virtual + .. _class_MainLoop_method__idle: - :ref:`bool` **_idle** **(** :ref:`float` delta **)** virtual diff --git a/classes/class_nativescript.rst b/classes/class_nativescript.rst index 69130581d..7c4a715ef 100644 --- a/classes/class_nativescript.rst +++ b/classes/class_nativescript.rst @@ -34,17 +34,17 @@ Properties Methods ------- -+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`String` | :ref:`get_class_documentation` **(** **)** const | -+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`String` | :ref:`get_method_documentation` **(** :ref:`String` method **)** const | -+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`String` | :ref:`get_property_documentation` **(** :ref:`String` path **)** const | -+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`String` | :ref:`get_signal_documentation` **(** :ref:`String` signal_name **)** const | -+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Object` | :ref:`new` **(** ... **)** vararg | -+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ ++-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`String` | :ref:`get_class_documentation` **(** **)** const | ++-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`String` | :ref:`get_method_documentation` **(** :ref:`String` method **)** const | ++-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`String` | :ref:`get_property_documentation` **(** :ref:`String` path **)** const | ++-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`String` | :ref:`get_signal_documentation` **(** :ref:`String` signal_name **)** const | ++-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`new` **(** ... **)** vararg | ++-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+ Property Descriptions --------------------- @@ -124,7 +124,7 @@ Returns the documentation string that was previously set with ``godot_nativescri .. _class_NativeScript_method_new: -- :ref:`Object` **new** **(** ... **)** vararg +- :ref:`Variant` **new** **(** ... **)** vararg Constructs a new object of the base type with a script of this type already attached. diff --git a/classes/class_object.rst b/classes/class_object.rst index 144148338..049ebcb62 100644 --- a/classes/class_object.rst +++ b/classes/class_object.rst @@ -9,7 +9,7 @@ Object ====== -**Inherited By:** :ref:`ARVRPositionalTracker`, :ref:`ARVRServer`, :ref:`AudioServer`, :ref:`CameraServer`, :ref:`ClassDB`, :ref:`EditorFileSystemDirectory`, :ref:`EditorNavigationMeshGenerator`, :ref:`EditorSelection`, :ref:`Engine`, :ref:`Geometry`, :ref:`GodotSharp`, :ref:`IP`, :ref:`Input`, :ref:`InputMap`, :ref:`JSON`, :ref:`JavaScript`, :ref:`MainLoop`, :ref:`Node`, :ref:`OS`, :ref:`Performance`, :ref:`Physics2DDirectBodyState`, :ref:`Physics2DDirectSpaceState`, :ref:`Physics2DServer`, :ref:`PhysicsDirectBodyState`, :ref:`PhysicsDirectSpaceState`, :ref:`PhysicsServer`, :ref:`ProjectSettings`, :ref:`Reference`, :ref:`ResourceLoader`, :ref:`ResourceSaver`, :ref:`TranslationServer`, :ref:`TreeItem`, :ref:`UndoRedo`, :ref:`VisualScriptEditor`, :ref:`VisualServer` +**Inherited By:** :ref:`ARVRPositionalTracker`, :ref:`ARVRServer`, :ref:`AudioServer`, :ref:`CameraServer`, :ref:`ClassDB`, :ref:`EditorFileSystemDirectory`, :ref:`EditorNavigationMeshGenerator`, :ref:`EditorSelection`, :ref:`Engine`, :ref:`Geometry`, :ref:`GodotSharp`, :ref:`IP`, :ref:`Input`, :ref:`InputMap`, :ref:`JSON`, :ref:`JSONRPC`, :ref:`JavaScript`, :ref:`MainLoop`, :ref:`Node`, :ref:`OS`, :ref:`Performance`, :ref:`Physics2DDirectBodyState`, :ref:`Physics2DDirectSpaceState`, :ref:`Physics2DServer`, :ref:`PhysicsDirectBodyState`, :ref:`PhysicsDirectSpaceState`, :ref:`PhysicsServer`, :ref:`ProjectSettings`, :ref:`Reference`, :ref:`ResourceLoader`, :ref:`ResourceSaver`, :ref:`TranslationServer`, :ref:`TreeItem`, :ref:`UndoRedo`, :ref:`VisualScriptEditor`, :ref:`VisualServer` **Category:** Core diff --git a/classes/class_os.rst b/classes/class_os.rst index 371ed7e91..9ed0e3b4e 100644 --- a/classes/class_os.rst +++ b/classes/class_os.rst @@ -175,6 +175,14 @@ Methods +-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Rect2` | :ref:`get_window_safe_area` **(** **)** const | +-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`global_menu_add_item` **(** :ref:`String` menu, :ref:`String` label, :ref:`Variant` id, :ref:`Variant` meta **)** | ++-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`global_menu_add_separator` **(** :ref:`String` menu **)** | ++-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`global_menu_clear` **(** :ref:`String` menu **)** | ++-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`global_menu_remove_item` **(** :ref:`String` menu, :ref:`int` idx **)** | ++-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`has_environment` **(** :ref:`String` environment **)** const | +-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`has_feature` **(** :ref:`String` tag_name **)** const | @@ -1098,6 +1106,30 @@ Returns the on-screen keyboard's height in pixels. Returns 0 if there is no keyb Returns unobscured area of the window where interactive controls should be rendered. +.. _class_OS_method_global_menu_add_item: + +- void **global_menu_add_item** **(** :ref:`String` menu, :ref:`String` label, :ref:`Variant` id, :ref:`Variant` meta **)** + +Add a new item with text "label" to global menu. Use "_dock" menu to add item to the macOS dock icon menu. + +.. _class_OS_method_global_menu_add_separator: + +- void **global_menu_add_separator** **(** :ref:`String` menu **)** + +Add a separator between items. Separators also occupy an index. + +.. _class_OS_method_global_menu_clear: + +- void **global_menu_clear** **(** :ref:`String` menu **)** + +Clear the global menu, in effect removing all items. + +.. _class_OS_method_global_menu_remove_item: + +- void **global_menu_remove_item** **(** :ref:`String` menu, :ref:`int` idx **)** + +Removes the item at index "idx" from the global menu. Note that the indexes of items after the removed item are going to be shifted by one. + .. _class_OS_method_has_environment: - :ref:`bool` **has_environment** **(** :ref:`String` environment **)** const diff --git a/classes/class_pluginscript.rst b/classes/class_pluginscript.rst index 5298f4d12..becf30495 100644 --- a/classes/class_pluginscript.rst +++ b/classes/class_pluginscript.rst @@ -21,16 +21,16 @@ Brief Description Methods ------- -+-----------------------------+------------------------------------------------------------------+ -| :ref:`Object` | :ref:`new` **(** ... **)** vararg | -+-----------------------------+------------------------------------------------------------------+ ++-------------------------------+------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`new` **(** ... **)** vararg | ++-------------------------------+------------------------------------------------------------------+ Method Descriptions ------------------- .. _class_PluginScript_method_new: -- :ref:`Object` **new** **(** ... **)** vararg +- :ref:`Variant` **new** **(** ... **)** vararg Returns a new instance of the script. diff --git a/classes/class_projectsettings.rst b/classes/class_projectsettings.rst index dd9c5612f..fac98adfe 100644 --- a/classes/class_projectsettings.rst +++ b/classes/class_projectsettings.rst @@ -34,6 +34,8 @@ Properties +-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`String` | :ref:`application/config/custom_user_dir_name` | "" | +-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`String` | :ref:`application/config/description` | "" | ++-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`String` | :ref:`application/config/icon` | "" | +-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`String` | :ref:`application/config/macos_native_icon` | "" | @@ -192,6 +194,8 @@ Properties +-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`editor/active` | false | +-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`String` | :ref:`editor/script_templates_search_path` | "res://script_templates" | ++-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`PoolStringArray` | :ref:`editor/search_in_file_extensions` | PoolStringArray( "gd", "shader" ) | +-----------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`gui/common/default_scroll_deadzone` | 0 | @@ -676,6 +680,16 @@ This user directory is used for storing persistent data (``user://`` filesystem) The :ref:`application/config/use_custom_user_dir` setting must be enabled for this to take effect. +.. _class_ProjectSettings_property_application/config/description: + +- :ref:`String` **application/config/description** + ++-----------+----+ +| *Default* | "" | ++-----------+----+ + +The project's description, displayed as a tooltip in the Project Manager when hovering the project. + .. _class_ProjectSettings_property_application/config/icon: - :ref:`String` **application/config/icon** @@ -1456,6 +1470,14 @@ If ``true``, enables vertical synchronization. This eliminates tearing that may Internal editor setting, don't touch. +.. _class_ProjectSettings_property_editor/script_templates_search_path: + +- :ref:`String` **editor/script_templates_search_path** + ++-----------+--------------------------+ +| *Default* | "res://script_templates" | ++-----------+--------------------------+ + .. _class_ProjectSettings_property_editor/search_in_file_extensions: - :ref:`PoolStringArray` **editor/search_in_file_extensions** diff --git a/classes/class_rigidbody2d.rst b/classes/class_rigidbody2d.rst index 1ea67a77a..f86eb54c5 100644 --- a/classes/class_rigidbody2d.rst +++ b/classes/class_rigidbody2d.rst @@ -356,7 +356,7 @@ Multiplies the gravity applied to the body. The body's gravity is calculated fro | *Getter* | get_inertia() | +----------+--------------------+ -The body's moment of inertia. This is like mass, but for rotation: it determines how much torque it takes to rotate the body. The moment of inertia is usually computed automatically from the mass and the shapes, but this function allows you to set a custom value. Set 0 (or negative) inertia to return to automatically computing it. +The body's moment of inertia. This is like mass, but for rotation: it determines how much torque it takes to rotate the body. The moment of inertia is usually computed automatically from the mass and the shapes, but this function allows you to set a custom value. Set 0 inertia to return to automatically computing it. .. _class_RigidBody2D_property_linear_damp: diff --git a/classes/class_scenetree.rst b/classes/class_scenetree.rst index d21c9e19f..0693b193f 100644 --- a/classes/class_scenetree.rst +++ b/classes/class_scenetree.rst @@ -123,6 +123,12 @@ Emitted whenever this ``SceneTree``'s :ref:`network_peer` id, :ref:`Nil` meta **)** + +Emitted whenever global menu item is clicked. + .. _class_SceneTree_signal_idle_frame: - **idle_frame** **(** **)** diff --git a/classes/class_spritebase3d.rst b/classes/class_spritebase3d.rst index 0999c0fe1..3b368593a 100644 --- a/classes/class_spritebase3d.rst +++ b/classes/class_spritebase3d.rst @@ -23,31 +23,33 @@ Brief Description Properties ---------- -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`AlphaCutMode` | :ref:`alpha_cut` | 0 | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| Vector3.Axis | :ref:`axis` | 2 | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`bool` | :ref:`centered` | true | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`bool` | :ref:`double_sided` | true | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`bool` | :ref:`flip_h` | false | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`bool` | :ref:`flip_v` | false | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`Color` | :ref:`modulate` | Color( 1, 1, 1, 1 ) | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`Vector2` | :ref:`offset` | Vector2( 0, 0 ) | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`float` | :ref:`opacity` | 1.0 | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`float` | :ref:`pixel_size` | 0.01 | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`bool` | :ref:`shaded` | false | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ -| :ref:`bool` | :ref:`transparent` | true | -+-----------------------------------------------------+---------------------------------------------------------------+---------------------+ ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`AlphaCutMode` | :ref:`alpha_cut` | 0 | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| Vector3.Axis | :ref:`axis` | 2 | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`BillboardMode` | :ref:`billboard` | 0 | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`bool` | :ref:`centered` | true | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`bool` | :ref:`double_sided` | true | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`bool` | :ref:`flip_h` | false | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`bool` | :ref:`flip_v` | false | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`Color` | :ref:`modulate` | Color( 1, 1, 1, 1 ) | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`Vector2` | :ref:`offset` | Vector2( 0, 0 ) | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`float` | :ref:`opacity` | 1.0 | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`float` | :ref:`pixel_size` | 0.01 | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`bool` | :ref:`shaded` | false | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ +| :ref:`bool` | :ref:`transparent` | true | ++----------------------------------------------------------+---------------------------------------------------------------+---------------------+ Methods ------- @@ -135,6 +137,18 @@ Property Descriptions The direction in which the front of the texture faces. +.. _class_SpriteBase3D_property_billboard: + +- :ref:`BillboardMode` **billboard** + ++-----------+---------------------------+ +| *Default* | 0 | ++-----------+---------------------------+ +| *Setter* | set_billboard_mode(value) | ++-----------+---------------------------+ +| *Getter* | get_billboard_mode() | ++-----------+---------------------------+ + .. _class_SpriteBase3D_property_centered: - :ref:`bool` **centered** diff --git a/classes/class_tabcontainer.rst b/classes/class_tabcontainer.rst index e115cd255..6cc916068 100644 --- a/classes/class_tabcontainer.rst +++ b/classes/class_tabcontainer.rst @@ -21,15 +21,17 @@ Tabbed container. Properties ---------- -+---------------------------------------------+-----------------------------------------------------------------------------------------+-------+ -| :ref:`int` | :ref:`current_tab` | 0 | -+---------------------------------------------+-----------------------------------------------------------------------------------------+-------+ -| :ref:`bool` | :ref:`drag_to_rearrange_enabled` | false | -+---------------------------------------------+-----------------------------------------------------------------------------------------+-------+ -| :ref:`TabAlign` | :ref:`tab_align` | 1 | -+---------------------------------------------+-----------------------------------------------------------------------------------------+-------+ -| :ref:`bool` | :ref:`tabs_visible` | true | -+---------------------------------------------+-----------------------------------------------------------------------------------------+-------+ ++---------------------------------------------+-----------------------------------------------------------------------------------------------+-------+ +| :ref:`int` | :ref:`current_tab` | 0 | ++---------------------------------------------+-----------------------------------------------------------------------------------------------+-------+ +| :ref:`bool` | :ref:`drag_to_rearrange_enabled` | false | ++---------------------------------------------+-----------------------------------------------------------------------------------------------+-------+ +| :ref:`TabAlign` | :ref:`tab_align` | 1 | ++---------------------------------------------+-----------------------------------------------------------------------------------------------+-------+ +| :ref:`bool` | :ref:`tabs_visible` | true | ++---------------------------------------------+-----------------------------------------------------------------------------------------------+-------+ +| :ref:`bool` | :ref:`use_hidden_tabs_for_min_size` | false | ++---------------------------------------------+-----------------------------------------------------------------------------------------------+-------+ Methods ------- @@ -217,6 +219,18 @@ The alignment of all tabs in the tab container. See the ``ALIGN_*`` constants fo If ``true``, tabs are visible. If ``false``, tabs' content and titles are hidden. +.. _class_TabContainer_property_use_hidden_tabs_for_min_size: + +- :ref:`bool` **use_hidden_tabs_for_min_size** + ++-----------+-----------------------------------------+ +| *Default* | false | ++-----------+-----------------------------------------+ +| *Setter* | set_use_hidden_tabs_for_min_size(value) | ++-----------+-----------------------------------------+ +| *Getter* | get_use_hidden_tabs_for_min_size() | ++-----------+-----------------------------------------+ + Method Descriptions ------------------- diff --git a/classes/class_transform.rst b/classes/class_transform.rst index af765d980..34243f587 100644 --- a/classes/class_transform.rst +++ b/classes/class_transform.rst @@ -195,11 +195,11 @@ Translates the transform by the specified offset. - :ref:`Variant` **xform** **(** :ref:`Variant` v **)** -Transforms the given :ref:`Vector3`, :ref:`Plane`, or :ref:`AABB` by this transform. +Transforms the given :ref:`Vector3`, :ref:`Plane`, :ref:`AABB`, or :ref:`PoolVector3Array` by this transform. .. _class_Transform_method_xform_inv: - :ref:`Variant` **xform_inv** **(** :ref:`Variant` v **)** -Inverse-transforms the given :ref:`Vector3`, :ref:`Plane`, or :ref:`AABB` by this transform. +Inverse-transforms the given :ref:`Vector3`, :ref:`Plane`, :ref:`AABB`, or :ref:`PoolVector3Array` by this transform. diff --git a/classes/class_transform2d.rst b/classes/class_transform2d.rst index 7d98d65a5..4d6b9f289 100644 --- a/classes/class_transform2d.rst +++ b/classes/class_transform2d.rst @@ -212,11 +212,11 @@ Translates the transform by the given offset. - :ref:`Variant` **xform** **(** :ref:`Variant` v **)** -Transforms the given :ref:`Vector2` or :ref:`Rect2` by this transform. +Transforms the given :ref:`Vector2`, :ref:`Rect2`, or :ref:`PoolVector2Array` by this transform. .. _class_Transform2D_method_xform_inv: - :ref:`Variant` **xform_inv** **(** :ref:`Variant` v **)** -Inverse-transforms the given :ref:`Vector2` or :ref:`Rect2` by this transform. +Inverse-transforms the given :ref:`Vector2`, :ref:`Rect2`, or :ref:`PoolVector2Array` by this transform. diff --git a/classes/class_treeitem.rst b/classes/class_treeitem.rst index 4604d17e2..3defa8925 100644 --- a/classes/class_treeitem.rst +++ b/classes/class_treeitem.rst @@ -59,6 +59,8 @@ Methods +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`get_icon_max_width` **(** :ref:`int` column **)** const | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Color` | :ref:`get_icon_modulate` **(** :ref:`int` column **)** const | ++-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Rect2` | :ref:`get_icon_region` **(** :ref:`int` column **)** const | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Variant` | :ref:`get_metadata` **(** :ref:`int` column **)** const | @@ -127,6 +129,8 @@ Methods +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_icon_max_width` **(** :ref:`int` column, :ref:`int` width **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`set_icon_modulate` **(** :ref:`int` column, :ref:`Color` modulate **)** | ++-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_icon_region` **(** :ref:`int` column, :ref:`Rect2` region **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_metadata` **(** :ref:`int` column, :ref:`Variant` meta **)** | @@ -312,6 +316,12 @@ Returns the given column's icon :ref:`Texture`. Error if no icon Returns the column's icon's maximum width. +.. _class_TreeItem_method_get_icon_modulate: + +- :ref:`Color` **get_icon_modulate** **(** :ref:`int` column **)** const + +Returns the :ref:`Color` modulating the column's icon. + .. _class_TreeItem_method_get_icon_region: - :ref:`Rect2` **get_icon_region** **(** :ref:`int` column **)** const @@ -512,6 +522,12 @@ Sets the given column's icon :ref:`Texture`. Sets the given column's icon's maximum width. +.. _class_TreeItem_method_set_icon_modulate: + +- void **set_icon_modulate** **(** :ref:`int` column, :ref:`Color` modulate **)** + +Modulates the given column's icon with ``modulate``. + .. _class_TreeItem_method_set_icon_region: - void **set_icon_region** **(** :ref:`int` column, :ref:`Rect2` region **)** diff --git a/classes/class_vector2.rst b/classes/class_vector2.rst index 064570581..4cc58d97b 100644 --- a/classes/class_vector2.rst +++ b/classes/class_vector2.rst @@ -73,6 +73,10 @@ Methods +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`normalized` **(** **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Vector2` | :ref:`posmod` **(** :ref:`float` mod **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Vector2` | :ref:`posmodv` **(** :ref:`Vector2` modv **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`project` **(** :ref:`Vector2` b **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`reflect` **(** :ref:`Vector2` n **)** | @@ -81,6 +85,8 @@ Methods +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`round` **(** **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Vector2` | :ref:`sign` **(** **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`slerp` **(** :ref:`Vector2` b, :ref:`float` t **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`slide` **(** :ref:`Vector2` n **)** | @@ -93,6 +99,10 @@ Methods Constants --------- +.. _class_Vector2_constant_AXIS_X: + +.. _class_Vector2_constant_AXIS_Y: + .. _class_Vector2_constant_ZERO: .. _class_Vector2_constant_ONE: @@ -107,11 +117,15 @@ Constants .. _class_Vector2_constant_DOWN: +- **AXIS_X** = **0** --- Enumerated value for the X axis. + +- **AXIS_Y** = **1** --- Enumerated value for the Y axis. + - **ZERO** = **Vector2( 0, 0 )** --- Zero vector. - **ONE** = **Vector2( 1, 1 )** --- One vector. -- **INF** = **Vector2( inf, inf )** --- Infinite vector. +- **INF** = **Vector2( inf, inf )** --- Infinity vector. - **LEFT** = **Vector2( -1, 0 )** --- Left unit vector. @@ -291,6 +305,18 @@ Moves the vector toward ``to`` by the fixed ``delta`` amount. Returns the vector scaled to unit length. Equivalent to ``v / v.length()``. +.. _class_Vector2_method_posmod: + +- :ref:`Vector2` **posmod** **(** :ref:`float` mod **)** + +Returns a vector composed of the ``fposmod`` of this vector's components and ``mod``. + +.. _class_Vector2_method_posmodv: + +- :ref:`Vector2` **posmodv** **(** :ref:`Vector2` modv **)** + +Returns a vector composed of the ``fposmod`` of this vector's components and ``modv``'s components. + .. _class_Vector2_method_project: - :ref:`Vector2` **project** **(** :ref:`Vector2` b **)** @@ -315,6 +341,12 @@ Returns the vector rotated by ``phi`` radians. See also :ref:`@GDScript.deg2rad< Returns the vector with all components rounded to the nearest integer, with halfway cases rounded away from zero. +.. _class_Vector2_method_sign: + +- :ref:`Vector2` **sign** **(** **)** + +Returns the vector with each component set to one or negative one, depending on the signs of the components. + .. _class_Vector2_method_slerp: - :ref:`Vector2` **slerp** **(** :ref:`Vector2` b, :ref:`float` t **)** diff --git a/classes/class_vector3.rst b/classes/class_vector3.rst index bd14b6a2c..e08567916 100644 --- a/classes/class_vector3.rst +++ b/classes/class_vector3.rst @@ -14,7 +14,7 @@ Vector3 Brief Description ----------------- -Vector class, which performs basic 3D vector math operations. +Vector used for 3D math. Properties ---------- @@ -75,6 +75,10 @@ Methods +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Basis` | :ref:`outer` **(** :ref:`Vector3` b **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Vector3` | :ref:`posmod` **(** :ref:`float` mod **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Vector3` | :ref:`posmodv` **(** :ref:`Vector3` modv **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`project` **(** :ref:`Vector3` b **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`reflect` **(** :ref:`Vector3` n **)** | @@ -83,6 +87,8 @@ Methods +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`round` **(** **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Vector3` | :ref:`sign` **(** **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`slerp` **(** :ref:`Vector3` b, :ref:`float` t **)** | +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`slide` **(** :ref:`Vector3` n **)** | @@ -121,15 +127,15 @@ Constants - **AXIS_X** = **0** --- Enumerated value for the X axis. Returned by :ref:`max_axis` and :ref:`min_axis`. -- **AXIS_Y** = **1** --- Enumerated value for the Y axis. +- **AXIS_Y** = **1** --- Enumerated value for the Y axis. Returned by :ref:`max_axis` and :ref:`min_axis`. -- **AXIS_Z** = **2** --- Enumerated value for the Z axis. +- **AXIS_Z** = **2** --- Enumerated value for the Z axis. Returned by :ref:`max_axis` and :ref:`min_axis`. - **ZERO** = **Vector3( 0, 0, 0 )** --- Zero vector. - **ONE** = **Vector3( 1, 1, 1 )** --- One vector. -- **INF** = **Vector3( inf, inf, inf )** --- Infinite vector. +- **INF** = **Vector3( inf, inf, inf )** --- Infinity vector. - **LEFT** = **Vector3( -1, 0, 0 )** --- Left unit vector. @@ -146,7 +152,7 @@ Constants Description ----------- -Vector3 is one of the core classes of the engine, and includes several built-in helper functions to perform basic vector math operations. +3-element structure that can be used to represent positions in 3D space or any other pair of numeric values. Tutorials --------- @@ -321,6 +327,18 @@ Returns the vector scaled to unit length. Equivalent to ``v / v.length()``. Returns the outer product with ``b``. +.. _class_Vector3_method_posmod: + +- :ref:`Vector3` **posmod** **(** :ref:`float` mod **)** + +Returns a vector composed of the ``fposmod`` of this vector's components and ``mod``. + +.. _class_Vector3_method_posmodv: + +- :ref:`Vector3` **posmodv** **(** :ref:`Vector3` modv **)** + +Returns a vector composed of the ``fposmod`` of this vector's components and ``modv``'s components. + .. _class_Vector3_method_project: - :ref:`Vector3` **project** **(** :ref:`Vector3` b **)** @@ -345,6 +363,12 @@ Rotates the vector around a given axis by ``phi`` radians. The axis must be a no Returns the vector with all components rounded to the nearest integer, with halfway cases rounded away from zero. +.. _class_Vector3_method_sign: + +- :ref:`Vector3` **sign** **(** **)** + +Returns the vector with each component set to one or negative one, depending on the signs of the components. + .. _class_Vector3_method_slerp: - :ref:`Vector3` **slerp** **(** :ref:`Vector3` b, :ref:`float` t **)** diff --git a/classes/class_visualshadernodecustom.rst b/classes/class_visualshadernodecustom.rst index 85bde5223..ca73651d6 100644 --- a/classes/class_visualshadernodecustom.rst +++ b/classes/class_visualshadernodecustom.rst @@ -62,6 +62,11 @@ In order for the node to be registered as an editor addon, you must use the ``to extends VisualShaderNodeCustom class_name VisualShaderNodeNoise +Tutorials +--------- + +- :doc:`../tutorials/plugins/editor/visual_shader_plugins` + Method Descriptions -------------------