diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/classes/@GDScript.xml | 18 | ||||
-rw-r--r-- | doc/classes/ARVRAnchor.xml | 16 | ||||
-rw-r--r-- | doc/classes/ARVRController.xml | 14 | ||||
-rw-r--r-- | doc/classes/ARVRPositionalTracker.xml | 7 | ||||
-rw-r--r-- | doc/classes/AStar.xml | 20 | ||||
-rw-r--r-- | doc/classes/File.xml | 8 | ||||
-rw-r--r-- | doc/classes/HeightMapShape.xml | 28 | ||||
-rw-r--r-- | doc/classes/RandomNumberGenerator.xml | 11 | ||||
-rw-r--r-- | doc/classes/StyleBoxFlat.xml | 3 | ||||
-rw-r--r-- | doc/classes/TextureRect.xml | 6 | ||||
-rw-r--r-- | doc/classes/TileMap.xml | 7 | ||||
-rw-r--r-- | doc/classes/Vector2.xml | 9 | ||||
-rw-r--r-- | doc/classes/Vector3.xml | 9 | ||||
-rwxr-xr-x | doc/tools/makerst.py | 3 |
14 files changed, 157 insertions, 2 deletions
diff --git a/doc/classes/@GDScript.xml b/doc/classes/@GDScript.xml index df52f8503a..e3eca57f2d 100644 --- a/doc/classes/@GDScript.xml +++ b/doc/classes/@GDScript.xml @@ -975,6 +975,24 @@ [/codeblock] </description> </method> + <method name="smoothstep"> + <return type="float"> + </return> + <argument index="0" name="from" type="float"> + </argument> + <argument index="1" name="to" type="float"> + </argument> + <argument index="2" name="weight" type="float"> + </argument> + <description> + Returns a number smoothly interpolated between the [code]from[/code] and [code]to[/code], based on the [code]weight[/code]. Similar to [method lerp], but interpolates faster at the beginning and slower at the end. + [codeblock] + smoothstep(0, 2, 0.5) # returns 0.15 + smoothstep(0, 2, 1.0) # returns 0.5 + smoothstep(0, 2, 2.0) # returns 1.0 + [/codeblock] + </description> + </method> <method name="sqrt"> <return type="float"> </return> diff --git a/doc/classes/ARVRAnchor.xml b/doc/classes/ARVRAnchor.xml index 5197c1c651..57ca74fdd3 100644 --- a/doc/classes/ARVRAnchor.xml +++ b/doc/classes/ARVRAnchor.xml @@ -27,6 +27,13 @@ Returns true if the anchor is being tracked and false if no anchor with this id is currently known. </description> </method> + <method name="get_mesh" qualifiers="const"> + <return type="Mesh"> + </return> + <description> + If provided by the ARVR Interface this returns a mesh object for the anchor. For an anchor this can be a shape related to the object being tracked or it can be a mesh that provides topology related to the anchor and can be used to create shadows/reflections on surfaces or for generating collision shapes. + </description> + </method> <method name="get_plane" qualifiers="const"> <return type="Plane"> </return> @@ -47,6 +54,15 @@ The anchor's id. You can set this before the anchor itself exists. The first anchor gets an id of [code]1[/code], the second an id of [code]2[/code], etc. When anchors get removed, the engine can then assign the corresponding id to new anchors. The most common situation where anchors 'disappear' is when the AR server identifies that two anchors represent different parts of the same plane and merges them. </member> </members> + <signals> + <signal name="mesh_updated"> + <argument index="0" name="mesh" type="Mesh"> + </argument> + <description> + Emitted when the mesh associated with the anchor changes or when one becomes available. This is especially important for topology that is constantly being mesh_updated. + </description> + </signal> + </signals> <constants> </constants> </class> diff --git a/doc/classes/ARVRController.xml b/doc/classes/ARVRController.xml index 1264f89f64..08e071ea1e 100644 --- a/doc/classes/ARVRController.xml +++ b/doc/classes/ARVRController.xml @@ -50,6 +50,13 @@ Returns the ID of the joystick object bound to this. Every controller tracked by the ARVR Server that has buttons and axis will also be registered as a joystick within Godot. This means that all the normal joystick tracking and input mapping will work for buttons and axis found on the AR/VR controllers. This ID is purely offered as information so you can link up the controller with its joystick entry. </description> </method> + <method name="get_mesh" qualifiers="const"> + <return type="Mesh"> + </return> + <description> + If provided by the ARVR Interface this returns a mesh associated with the controller. This can be used to visualise the controller. + </description> + </method> <method name="is_button_pressed" qualifiers="const"> <return type="int"> </return> @@ -86,6 +93,13 @@ Emitted when a button on this controller is released. </description> </signal> + <signal name="mesh_updated"> + <argument index="0" name="mesh" type="Mesh"> + </argument> + <description> + Emitted when the mesh associated with the controller changes or when one becomes available. Generally speaking this will be a static mesh after becoming available. + </description> + </signal> </signals> <constants> </constants> diff --git a/doc/classes/ARVRPositionalTracker.xml b/doc/classes/ARVRPositionalTracker.xml index c1be8d2356..c2e48b878b 100644 --- a/doc/classes/ARVRPositionalTracker.xml +++ b/doc/classes/ARVRPositionalTracker.xml @@ -27,6 +27,13 @@ If this is a controller that is being tracked the controller will also be represented by a joystick entry with this id. </description> </method> + <method name="get_mesh" qualifiers="const"> + <return type="Mesh"> + </return> + <description> + Returns the mesh related to a controller or anchor point if one is available. + </description> + </method> <method name="get_name" qualifiers="const"> <return type="String"> </return> diff --git a/doc/classes/AStar.xml b/doc/classes/AStar.xml index 5a62c69a67..3e478467ff 100644 --- a/doc/classes/AStar.xml +++ b/doc/classes/AStar.xml @@ -226,6 +226,15 @@ Returns whether a point associated with the given id exists. </description> </method> + <method name="is_point_disabled" qualifiers="const"> + <return type="bool"> + </return> + <argument index="0" name="id" type="int"> + </argument> + <description> + Returns whether a point is disabled or not for pathfinding. By default, all points are enabled. + </description> + </method> <method name="remove_point"> <return type="void"> </return> @@ -235,6 +244,17 @@ Removes the point associated with the given id from the points pool. </description> </method> + <method name="set_point_disabled"> + <return type="void"> + </return> + <argument index="0" name="id" type="int"> + </argument> + <argument index="1" name="disabled" type="bool" default="true"> + </argument> + <description> + Disables or enables the specified point for pathfinding. Useful for making a temporary obstacle. + </description> + </method> <method name="set_point_position"> <return type="void"> </return> diff --git a/doc/classes/File.xml b/doc/classes/File.xml index 533a6d6399..8a785ab263 100644 --- a/doc/classes/File.xml +++ b/doc/classes/File.xml @@ -84,6 +84,7 @@ </return> <description> Returns the whole file as a [String]. + Text is interpreted as being UTF-8 encoded. </description> </method> <method name="get_buffer" qualifiers="const"> @@ -102,6 +103,7 @@ </argument> <description> Returns the next value of the file in CSV (Comma Separated Values) format. You can pass a different delimiter to use other than the default "," (comma), it should be one character long. + Text is interpreted as being UTF-8 encoded. </description> </method> <method name="get_double" qualifiers="const"> @@ -137,6 +139,7 @@ </return> <description> Returns the next line of the file as a [String]. + Text is interpreted as being UTF-8 encoded. </description> </method> <method name="get_md5" qualifiers="const"> @@ -162,6 +165,7 @@ </return> <description> Returns a [String] saved in Pascal format from the file. + Text is interpreted as being UTF-8 encoded. </description> </method> <method name="get_path" qualifiers="const"> @@ -340,6 +344,7 @@ </argument> <description> Store the given [PoolStringArray] in the file as a line formatted in the CSV (Comma Separated Values) format. You can pass a different delimiter to use other than the default "," (comma), it should be one character long. + Text will be encoded as UTF-8. </description> </method> <method name="store_double"> @@ -367,6 +372,7 @@ </argument> <description> Stores the given [String] as a line in the file. + Text will be encoded as UTF-8. </description> </method> <method name="store_pascal_string"> @@ -376,6 +382,7 @@ </argument> <description> Stores the given [String] as a line in the file in Pascal format (i.e. also store the length of the string). + Text will be encoded as UTF-8. </description> </method> <method name="store_real"> @@ -394,6 +401,7 @@ </argument> <description> Stores the given [String] in the file. + Text will be encoded as UTF-8. </description> </method> <method name="store_var"> diff --git a/doc/classes/HeightMapShape.xml b/doc/classes/HeightMapShape.xml new file mode 100644 index 0000000000..ec2e18bd7d --- /dev/null +++ b/doc/classes/HeightMapShape.xml @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="HeightMapShape" inherits="Shape" category="Core" version="3.2"> + <brief_description> + Height map shape for 3D physics (bullet only) + </brief_description> + <description> + Height map shape resource, which can be added to a [PhysicsBody] or [Area]. + </description> + <tutorials> + </tutorials> + <demos> + </demos> + <methods> + </methods> + <members> + <member name="map_data" type="PoolRealArray" setter="set_map_data" getter="get_map_data"> + Height map data, pool array must be of [member map_width] * [member map_depth] size. + </member> + <member name="map_depth" type="int" setter="set_map_depth" getter="get_map_depth"> + Depth of the height map data. Changing this will resize the [member map_data]. + </member> + <member name="map_width" type="int" setter="set_map_width" getter="get_map_width"> + Width of the height map data. Changing this will resize the [member map_data]. + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/RandomNumberGenerator.xml b/doc/classes/RandomNumberGenerator.xml index 6fa2d44fd0..07c9f2a74b 100644 --- a/doc/classes/RandomNumberGenerator.xml +++ b/doc/classes/RandomNumberGenerator.xml @@ -28,6 +28,17 @@ Generates pseudo-random float between [code]from[/code] and [code]to[/code]. </description> </method> + <method name="randfn"> + <return type="float"> + </return> + <argument index="0" name="mean" type="float" default="0.0"> + </argument> + <argument index="1" name="deviation" type="float" default="1.0"> + </argument> + <description> + Generates normally(gaussian) distributed pseudo-random number, using Box-Muller transform with the specified [code]mean[/code] and a standard [code]deviation[/code]. + </description> + </method> <method name="randi"> <return type="int"> </return> diff --git a/doc/classes/StyleBoxFlat.xml b/doc/classes/StyleBoxFlat.xml index 448b635886..d74f481f55 100644 --- a/doc/classes/StyleBoxFlat.xml +++ b/doc/classes/StyleBoxFlat.xml @@ -151,6 +151,9 @@ <member name="shadow_size" type="int" setter="set_shadow_size" getter="get_shadow_size"> The shadow size in pixels. </member> + <member name="shadow_offset" type="Vector2" setter="set_shadow_offset" getter="get_shadow_offset"> + The shadow offset in pixels. Adjusts the position of the shadow relatively to the stylebox. + </member> </members> <constants> </constants> diff --git a/doc/classes/TextureRect.xml b/doc/classes/TextureRect.xml index 13fd762908..7f26fe18e5 100644 --- a/doc/classes/TextureRect.xml +++ b/doc/classes/TextureRect.xml @@ -22,6 +22,12 @@ <member name="texture" type="Texture" setter="set_texture" getter="get_texture"> The node's [Texture] resource. </member> + <member name="flip_h" type="bool" setter="set_flip_h" getter="is_flipped_h"> + If [code]true[/code], texture is flipped horizontally. Default value: [code]false[/code]. + </member> + <member name="flip_v" type="bool" setter="set_flip_v" getter="is_flipped_v"> + If [code]true[/code], texture is flipped vertically. Default value: [code]false[/code]. + </member> </members> <constants> <constant name="STRETCH_SCALE_ON_EXPAND" value="0" enum="StretchMode"> diff --git a/doc/classes/TileMap.xml b/doc/classes/TileMap.xml index fe917acaae..3c047487e0 100644 --- a/doc/classes/TileMap.xml +++ b/doc/classes/TileMap.xml @@ -165,6 +165,13 @@ Optionally, the tile can also be flipped, transposed, or given autotile coordinates. Note that data such as navigation polygons and collision shapes are not immediately updated for performance reasons. If you need these to be immediately updated, you can call [method update_dirty_quadrants]. + Overriding this method also overrides it internally, allowing custom logic to be implemented when tiles are placed/removed: + [codeblock] + func set_cell(x, y, tile, flip_x, flip_y, transpose, autotile_coord) + # Write your custom logic here. + # To call the default method: + .set_cell(x, y, tile, flip_x, flip_y, transpose, autotile_coord) + [/codeblock] </description> </method> <method name="set_cellv"> diff --git a/doc/classes/Vector2.xml b/doc/classes/Vector2.xml index f1fd0173fe..2f4d3fe3dc 100644 --- a/doc/classes/Vector2.xml +++ b/doc/classes/Vector2.xml @@ -112,6 +112,15 @@ Cubicly interpolates between this vector and [code]b[/code] using [code]pre_a[/code] and [code]post_b[/code] as handles, and returns the result at position [code]t[/code]. [code]t[/code] is in the range of [code]0.0 - 1.0[/code], representing the amount of interpolation. </description> </method> + <method name="direction_to"> + <return type="Vector2"> + </return> + <argument index="0" name="b" type="Vector2"> + </argument> + <description> + Returns the normalized vector pointing from this vector to [code]b[/code]. + </description> + </method> <method name="distance_squared_to"> <return type="float"> </return> diff --git a/doc/classes/Vector3.xml b/doc/classes/Vector3.xml index 7b0d1c5a97..f1363f4fad 100644 --- a/doc/classes/Vector3.xml +++ b/doc/classes/Vector3.xml @@ -81,6 +81,15 @@ Performs a cubic interpolation between vectors [code]pre_a[/code], [code]a[/code], [code]b[/code], [code]post_b[/code] ([code]a[/code] is current), by the given amount [code]t[/code]. [code]t[/code] is in the range of [code]0.0 - 1.0[/code], representing the amount of interpolation. </description> </method> + <method name="direction_to"> + <return type="Vector3"> + </return> + <argument index="0" name="b" type="Vector3"> + </argument> + <description> + Returns the normalized vector pointing from this vector to [code]b[/code]. + </description> + </method> <method name="distance_squared_to"> <return type="float"> </return> diff --git a/doc/tools/makerst.py b/doc/tools/makerst.py index dc6d270c08..e81b4db13e 100755 --- a/doc/tools/makerst.py +++ b/doc/tools/makerst.py @@ -1,11 +1,10 @@ #!/usr/bin/env python3 import argparse -import sys import os import re import xml.etree.ElementTree as ET -from collections import defaultdict, OrderedDict +from collections import OrderedDict # Uncomment to do type checks. I have it commented out so it works below Python 3.5 #from typing import List, Dict, TextIO, Tuple, Iterable, Optional, DefaultDict, Any, Union |