Skip to content

Commit

Permalink
Fix the doc descriptions where they got lost due to adding StringName…
Browse files Browse the repository at this point in the history
… to Variants. Also fixed smaller issues where I ran into them.
  • Loading branch information
Relintai committed Dec 20, 2023
1 parent 4f6d95d commit cf76e6d
Show file tree
Hide file tree
Showing 39 changed files with 433 additions and 0 deletions.
1 change: 1 addition & 0 deletions doc/classes/AnimatedSprite.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<argument index="0" name="anim" type="StringName" default="@&quot;&quot;" />
<argument index="1" name="backwards" type="bool" default="false" />
<description>
Plays the animation named [code]anim[/code]. If no [code]anim[/code] is provided, the current animation is played. If [code]backwards[/code] is [code]true[/code], the animation will be played in reverse.
</description>
</method>
<method name="stop">
Expand Down
1 change: 1 addition & 0 deletions doc/classes/AnimatedSprite3D.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
<return type="void" />
<argument index="0" name="anim" type="StringName" default="@&quot;&quot;" />
<description>
Plays the animation named [code]anim[/code]. If no [code]anim[/code] is provided, the current animation is played.
</description>
</method>
<method name="stop">
Expand Down
2 changes: 2 additions & 0 deletions doc/classes/Animation.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
<argument index="1" name="time" type="float" />
<argument index="2" name="animation" type="StringName" />
<description>
Inserts a key with value [code]animation[/code] at the given [code]time[/code] (in seconds). The [code]track_idx[/code] must be the index of an Animation Track.
</description>
</method>
<method name="animation_track_set_key_animation">
Expand All @@ -50,6 +51,7 @@
<argument index="1" name="key_idx" type="int" />
<argument index="2" name="animation" type="StringName" />
<description>
Sets the key identified by [code]key_idx[/code] to value [code]animation[/code]. The [code]track_idx[/code] must be the index of an Animation Track.
</description>
</method>
<method name="audio_track_get_key_end_offset" qualifiers="const">
Expand Down
3 changes: 3 additions & 0 deletions doc/classes/AnimationNode.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
<argument index="3" name="seeked" type="bool" />
<argument index="4" name="blend" type="float" />
<description>
Blend an animation by [code]blend[/code] amount (name must be valid in the linked [AnimationPlayer]). A [code]time[/code] and [code]delta[/code] may be passed, as well as whether [code]seek[/code] happened.
</description>
</method>
<method name="blend_input">
Expand All @@ -50,6 +51,7 @@
<argument index="5" name="filter" type="int" enum="AnimationNode.FilterAction" default="0" />
<argument index="6" name="optimize" type="bool" default="true" />
<description>
Blend another animation node (in case this node contains children animation nodes). This function is only useful if you inherit from [AnimationRootNode] instead, else editors will not display your node for addition.
</description>
</method>
<method name="get_caption" qualifiers="virtual">
Expand Down Expand Up @@ -146,6 +148,7 @@
<argument index="0" name="name" type="StringName" />
<argument index="1" name="value" type="Variant" />
<description>
Sets a custom parameter. These are used as local memory, because resources can be reused across the tree or scenes.
</description>
</method>
</methods>
Expand Down
9 changes: 9 additions & 0 deletions doc/classes/AnimationNodeBlendTree.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<argument index="1" name="node" type="AnimationNode" />
<argument index="2" name="position" type="Vector2" default="Vector2( 0, 0 )" />
<description>
Adds an [AnimationNode] at the given [code]position[/code]. The [code]name[/code] is used to identify the created sub-node later.
</description>
</method>
<method name="connect_node">
Expand All @@ -25,51 +26,59 @@
<argument index="1" name="input_index" type="int" />
<argument index="2" name="output_node" type="StringName" />
<description>
Connects the output of an [AnimationNode] as input for another [AnimationNode], at the input port specified by [code]input_index[/code].
</description>
</method>
<method name="disconnect_node">
<return type="void" />
<argument index="0" name="input_node" type="StringName" />
<argument index="1" name="input_index" type="int" />
<description>
Disconnects the node connected to the specified input.
</description>
</method>
<method name="get_node" qualifiers="const">
<return type="AnimationNode" />
<argument index="0" name="name" type="StringName" />
<description>
Returns the sub-node with the specified [code]name[/code].
</description>
</method>
<method name="get_node_position" qualifiers="const">
<return type="Vector2" />
<argument index="0" name="name" type="StringName" />
<description>
Returns the position of the sub-node with the specified [code]name[/code].
</description>
</method>
<method name="has_node" qualifiers="const">
<return type="bool" />
<argument index="0" name="name" type="StringName" />
<description>
Returns [code]true[/code] if a sub-node with specified [code]name[/code] exists.
</description>
</method>
<method name="remove_node">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<description>
Removes a sub-node.
</description>
</method>
<method name="rename_node">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<argument index="1" name="new_name" type="StringName" />
<description>
Changes the name of a sub-node.
</description>
</method>
<method name="set_node_position">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<argument index="1" name="position" type="Vector2" />
<description>
Modifies the position of a sub-node.
</description>
</method>
</methods>
Expand Down
13 changes: 13 additions & 0 deletions doc/classes/AnimationNodeStateMachine.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
<argument index="1" name="node" type="AnimationNode" />
<argument index="2" name="position" type="Vector2" default="Vector2( 0, 0 )" />
<description>
Adds a new node to the graph. The [code]position[/code] is used for display in the editor.
</description>
</method>
<method name="add_transition">
Expand All @@ -29,6 +30,7 @@
<argument index="1" name="to" type="StringName" />
<argument index="2" name="transition" type="AnimationNodeStateMachineTransition" />
<description>
Adds a transition between the given nodes.
</description>
</method>
<method name="get_end_node" qualifiers="const">
Expand All @@ -47,6 +49,7 @@
<return type="AnimationNode" />
<argument index="0" name="name" type="StringName" />
<description>
Returns the animation node with the given name.
</description>
</method>
<method name="get_node_name" qualifiers="const">
Expand All @@ -60,6 +63,7 @@
<return type="Vector2" />
<argument index="0" name="name" type="StringName" />
<description>
Returns the given node's coordinates. Used for display in the editor.
</description>
</method>
<method name="get_start_node" qualifiers="const">
Expand Down Expand Up @@ -99,26 +103,30 @@
<return type="bool" />
<argument index="0" name="name" type="StringName" />
<description>
Returns [code]true[/code] if the graph contains the given node.
</description>
</method>
<method name="has_transition" qualifiers="const">
<return type="bool" />
<argument index="0" name="from" type="StringName" />
<argument index="1" name="to" type="StringName" />
<description>
Returns [code]true[/code] if there is a transition between the given nodes.
</description>
</method>
<method name="remove_node">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<description>
Deletes the given node from the graph.
</description>
</method>
<method name="remove_transition">
<return type="void" />
<argument index="0" name="from" type="StringName" />
<argument index="1" name="to" type="StringName" />
<description>
Deletes the transition between the two specified nodes.
</description>
</method>
<method name="remove_transition_by_index">
Expand All @@ -133,19 +141,22 @@
<argument index="0" name="name" type="StringName" />
<argument index="1" name="new_name" type="StringName" />
<description>
Renames the given node.
</description>
</method>
<method name="replace_node">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<argument index="1" name="node" type="AnimationNode" />
<description>
Replaces the node and keeps its transitions unchanged.
</description>
</method>
<method name="set_end_node">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<description>
Sets the given node as the graph end point.
</description>
</method>
<method name="set_graph_offset">
Expand All @@ -160,12 +171,14 @@
<argument index="0" name="name" type="StringName" />
<argument index="1" name="position" type="Vector2" />
<description>
Sets the node's coordinates. Used for display in the editor.
</description>
</method>
<method name="set_start_node">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<description>
Sets the given node as the graph start point.
</description>
</method>
</methods>
Expand Down
2 changes: 2 additions & 0 deletions doc/classes/AnimationNodeStateMachinePlayback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
<return type="void" />
<argument index="0" name="node" type="StringName" />
<description>
Starts playing the given animation.
</description>
</method>
<method name="stop">
Expand All @@ -60,6 +61,7 @@
<return type="void" />
<argument index="0" name="to_node" type="StringName" />
<description>
Transitions from the current state to another one, following the shortest path.
</description>
</method>
</methods>
Expand Down
16 changes: 16 additions & 0 deletions doc/classes/AnimationPlayer.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
<argument index="0" name="name" type="StringName" />
<argument index="1" name="animation" type="Animation" />
<description>
Adds [code]animation[/code] to the player accessible with the key [code]name[/code].
</description>
</method>
<method name="advance">
Expand All @@ -32,13 +33,15 @@
<return type="StringName" />
<argument index="0" name="anim_from" type="StringName" />
<description>
Returns the name of the next animation in the queue.
</description>
</method>
<method name="animation_set_next">
<return type="void" />
<argument index="0" name="anim_from" type="StringName" />
<argument index="1" name="anim_to" type="StringName" />
<description>
Triggers the [code]anim_to[/code] animation when the [code]anim_from[/code] animation completes.
</description>
</method>
<method name="clear_caches">
Expand All @@ -64,6 +67,7 @@
<return type="Animation" />
<argument index="0" name="name" type="StringName" />
<description>
Returns the [Animation] with the key [code]name[/code]. If the animation does not exist, [code]null[/code] is returned and an error is logged.
</description>
</method>
<method name="get_animation_list" qualifiers="const">
Expand All @@ -77,6 +81,7 @@
<argument index="0" name="anim_from" type="StringName" />
<argument index="1" name="anim_to" type="StringName" />
<description>
Gets the blend time (in seconds) between two animations, referenced by their names.
</description>
</method>
<method name="get_playing_speed" qualifiers="const">
Expand All @@ -95,6 +100,7 @@
<return type="bool" />
<argument index="0" name="name" type="StringName" />
<description>
Returns [code]true[/code] if the [AnimationPlayer] stores an [Animation] with key [code]name[/code].
</description>
</method>
<method name="is_playing" qualifiers="const">
Expand All @@ -110,32 +116,41 @@
<argument index="2" name="custom_speed" type="float" default="1.0" />
<argument index="3" name="from_end" type="bool" default="false" />
<description>
Plays the animation with key [code]name[/code]. Custom blend times and speed can be set. If [code]custom_speed[/code] is negative and [code]from_end[/code] is [code]true[/code], the animation will play backwards (which is equivalent to calling [method play_backwards]).
The [AnimationPlayer] keeps track of its current or last played animation with [member assigned_animation]. If this method is called with that same animation [code]name[/code], or with no [code]name[/code] parameter, the assigned animation will resume playing if it was paused, or restart if it was stopped (see [method stop] for both pause and stop). If the animation was already playing, it will keep playing.
[b]Note:[/b] The animation will be updated the next time the [AnimationPlayer] is processed. If other variables are updated at the same time this is called, they may be updated too early. To perform the update immediately, call [code]advance(0)[/code].
</description>
</method>
<method name="play_backwards">
<return type="void" />
<argument index="0" name="name" type="StringName" default="&quot;&quot;" />
<argument index="1" name="custom_blend" type="float" default="-1" />
<description>
Plays the animation with key [code]name[/code] in reverse.
This method is a shorthand for [method play] with [code]custom_speed = -1.0[/code] and [code]from_end = true[/code], so see its description for more information.
</description>
</method>
<method name="queue">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<description>
Queues an animation for playback once the current one is done.
[b]Note:[/b] If a looped animation is currently playing, the queued animation will never play unless the looped animation is stopped somehow.
</description>
</method>
<method name="remove_animation">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<description>
Removes the animation with key [code]name[/code].
</description>
</method>
<method name="rename_animation">
<return type="void" />
<argument index="0" name="name" type="StringName" />
<argument index="1" name="newname" type="StringName" />
<description>
Renames an existing animation with key [code]name[/code] to [code]newname[/code].
</description>
</method>
<method name="seek">
Expand All @@ -153,6 +168,7 @@
<argument index="1" name="anim_to" type="StringName" />
<argument index="2" name="sec" type="float" />
<description>
Specifies a blend time (in seconds) between two animations, referenced by their names.
</description>
</method>
<method name="stop">
Expand Down
2 changes: 2 additions & 0 deletions doc/classes/ArrayMesh.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
<return type="void" />
<argument index="0" name="name" type="StringName" />
<description>
Adds name for a blend shape that will be added with [method add_surface_from_arrays]. Must be called before surface is added.
</description>
</method>
<method name="add_surface_from_arrays">
Expand Down Expand Up @@ -85,6 +86,7 @@
<argument index="0" name="index" type="int" />
<argument index="1" name="name" type="StringName" />
<description>
Sets the name of the specified blend shape.
</description>
</method>
<method name="surface_find_by_name" qualifiers="const">
Expand Down
2 changes: 2 additions & 0 deletions doc/classes/AudioServer.xml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@
<return type="int" />
<argument index="0" name="bus_name" type="StringName" />
<description>
Returns the index of the bus with the name [code]bus_name[/code].
</description>
</method>
<method name="get_bus_name" qualifiers="const">
Expand Down Expand Up @@ -262,6 +263,7 @@
<argument index="0" name="bus_idx" type="int" />
<argument index="1" name="send" type="StringName" />
<description>
Connects the output of the bus at [code]bus_idx[/code] to the bus named [code]send[/code].
</description>
</method>
<method name="set_bus_solo">
Expand Down
Loading

0 comments on commit cf76e6d

Please sign in to comment.