Merge pull request #81245 from AThousandShips/future_proof_4_1
[4.1] Future proof links in docs
This commit is contained in:
commit
f2644f0cb0
|
@ -341,7 +341,7 @@
|
||||||
- 1.0: Linear
|
- 1.0: Linear
|
||||||
- Greater than 1.0 (exclusive): Ease in
|
- Greater than 1.0 (exclusive): Ease in
|
||||||
[/codeblock]
|
[/codeblock]
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/ease_cheatsheet.png]ease() curve values cheatsheet[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/ease_cheatsheet.png]ease() curve values cheatsheet[/url]
|
||||||
See also [method smoothstep]. If you need to perform more advanced transitions, use [method Tween.interpolate_value].
|
See also [method smoothstep]. If you need to perform more advanced transitions, use [method Tween.interpolate_value].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
|
@ -1203,7 +1203,7 @@
|
||||||
smoothstep(0, 2, 2.0) # Returns 1.0
|
smoothstep(0, 2, 2.0) # Returns 1.0
|
||||||
[/codeblock]
|
[/codeblock]
|
||||||
Compared to [method ease] with a curve value of [code]-1.6521[/code], [method smoothstep] returns the smoothest possible curve with no sudden changes in the derivative. If you need to perform more advanced transitions, use [Tween] or [AnimationPlayer].
|
Compared to [method ease] with a curve value of [code]-1.6521[/code], [method smoothstep] returns the smoothest possible curve with no sudden changes in the derivative. If you need to perform more advanced transitions, use [Tween] or [AnimationPlayer].
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/smoothstep_ease_comparison.png]Comparison between smoothstep() and ease(x, -1.6521) return values[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/smoothstep_ease_comparison.png]Comparison between smoothstep() and ease(x, -1.6521) return values[/url]
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="snapped">
|
<method name="snapped">
|
||||||
|
|
|
@ -58,7 +58,7 @@
|
||||||
<return type="bool" />
|
<return type="bool" />
|
||||||
<param index="0" name="world_point" type="Vector3" />
|
<param index="0" name="world_point" type="Vector3" />
|
||||||
<description>
|
<description>
|
||||||
Returns [code]true[/code] if the given position is behind the camera (the blue part of the linked diagram). [url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/camera3d_position_frustum.png]See this diagram[/url] for an overview of position query methods.
|
Returns [code]true[/code] if the given position is behind the camera (the blue part of the linked diagram). [url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/camera3d_position_frustum.png]See this diagram[/url] for an overview of position query methods.
|
||||||
[b]Note:[/b] A position which returns [code]false[/code] may still be outside the camera's field of view.
|
[b]Note:[/b] A position which returns [code]false[/code] may still be outside the camera's field of view.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
|
@ -66,7 +66,7 @@
|
||||||
<return type="bool" />
|
<return type="bool" />
|
||||||
<param index="0" name="world_point" type="Vector3" />
|
<param index="0" name="world_point" type="Vector3" />
|
||||||
<description>
|
<description>
|
||||||
Returns [code]true[/code] if the given position is inside the camera's frustum (the green part of the linked diagram). [url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/camera3d_position_frustum.png]See this diagram[/url] for an overview of position query methods.
|
Returns [code]true[/code] if the given position is inside the camera's frustum (the green part of the linked diagram). [url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/camera3d_position_frustum.png]See this diagram[/url] for an overview of position query methods.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="make_current">
|
<method name="make_current">
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
A color represented in RGBA format by a red ([member r]), green ([member g]), blue ([member b]), and alpha ([member a]) component. Each component is a 16-bit floating-point value, usually ranging from [code]0.0[/code] to [code]1.0[/code]. Some properties (such as [member CanvasItem.modulate]) may support values greater than [code]1.0[/code], for overbright or HDR (High Dynamic Range) colors.
|
A color represented in RGBA format by a red ([member r]), green ([member g]), blue ([member b]), and alpha ([member a]) component. Each component is a 16-bit floating-point value, usually ranging from [code]0.0[/code] to [code]1.0[/code]. Some properties (such as [member CanvasItem.modulate]) may support values greater than [code]1.0[/code], for overbright or HDR (High Dynamic Range) colors.
|
||||||
Colors can be created in various ways: By the various [Color] constructors, by static methods such as [method from_hsv], and by using a name from the set of standardized colors based on [url=https://en.wikipedia.org/wiki/X11_color_names]X11 color names[/url] with the addition of [constant TRANSPARENT]. GDScript also provides [method @GDScript.Color8], which uses integers from [code]0[/code] to [code]255[/code] and doesn't support overbright colors.
|
Colors can be created in various ways: By the various [Color] constructors, by static methods such as [method from_hsv], and by using a name from the set of standardized colors based on [url=https://en.wikipedia.org/wiki/X11_color_names]X11 color names[/url] with the addition of [constant TRANSPARENT]. GDScript also provides [method @GDScript.Color8], which uses integers from [code]0[/code] to [code]255[/code] and doesn't support overbright colors.
|
||||||
[b]Note:[/b] In a boolean context, a Color will evaluate to [code]false[/code] if it is equal to [code]Color(0, 0, 0, 1)[/code] (opaque black). Otherwise, a Color will always evaluate to [code]true[/code].
|
[b]Note:[/b] In a boolean context, a Color will evaluate to [code]false[/code] if it is equal to [code]Color(0, 0, 0, 1)[/code] (opaque black). Otherwise, a Color will always evaluate to [code]true[/code].
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/color_constants.png]Color constants cheatsheet[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/color_constants.png]Color constants cheatsheet[/url]
|
||||||
</description>
|
</description>
|
||||||
<tutorials>
|
<tutorials>
|
||||||
<link title="2D GD Paint Demo">https://godotengine.org/asset-library/asset/517</link>
|
<link title="2D GD Paint Demo">https://godotengine.org/asset-library/asset/517</link>
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
<param index="0" name="point" type="Vector2" />
|
<param index="0" name="point" type="Vector2" />
|
||||||
<description>
|
<description>
|
||||||
Returns the angle between the node and the [param point] in radians.
|
Returns the angle between the node and the [param point] in radians.
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/node2d_get_angle_to.png]Illustration of the returned angle.[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/node2d_get_angle_to.png]Illustration of the returned angle.[/url]
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_relative_transform_to_parent" qualifiers="const">
|
<method name="get_relative_transform_to_parent" qualifiers="const">
|
||||||
|
|
|
@ -88,7 +88,7 @@
|
||||||
[/csharp]
|
[/csharp]
|
||||||
[/codeblocks]
|
[/codeblocks]
|
||||||
Some [Tweener]s use transitions and eases. The first accepts a [enum TransitionType] constant, and refers to the way the timing of the animation is handled (see [url=https://easings.net/]easings.net[/url] for some examples). The second accepts an [enum EaseType] constant, and controls where the [code]trans_type[/code] is applied to the interpolation (in the beginning, the end, or both). If you don't know which transition and easing to pick, you can try different [enum TransitionType] constants with [constant EASE_IN_OUT], and use the one that looks best.
|
Some [Tweener]s use transitions and eases. The first accepts a [enum TransitionType] constant, and refers to the way the timing of the animation is handled (see [url=https://easings.net/]easings.net[/url] for some examples). The second accepts an [enum EaseType] constant, and controls where the [code]trans_type[/code] is applied to the interpolation (in the beginning, the end, or both). If you don't know which transition and easing to pick, you can try different [enum TransitionType] constants with [constant EASE_IN_OUT], and use the one that looks best.
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/tween_cheatsheet.webp]Tween easing and transition types cheatsheet[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/tween_cheatsheet.webp]Tween easing and transition types cheatsheet[/url]
|
||||||
[b]Note:[/b] Tweens are not designed to be re-used and trying to do so results in an undefined behavior. Create a new Tween for each animation and every time you replay an animation from start. Keep in mind that Tweens start immediately, so only create a Tween when you want to start animating.
|
[b]Note:[/b] Tweens are not designed to be re-used and trying to do so results in an undefined behavior. Create a new Tween for each animation and every time you replay an animation from start. Keep in mind that Tweens start immediately, so only create a Tween when you want to start animating.
|
||||||
[b]Note:[/b] The tween is processed after all of the nodes in the current frame, i.e. node's [method Node._process] method would be called before the timer (or [method Node._physics_process] depending on the value passed to [method set_process_mode]).
|
[b]Note:[/b] The tween is processed after all of the nodes in the current frame, i.e. node's [method Node._process] method would be called before the timer (or [method Node._physics_process] depending on the value passed to [method set_process_mode]).
|
||||||
</description>
|
</description>
|
||||||
|
|
|
@ -59,7 +59,7 @@
|
||||||
<description>
|
<description>
|
||||||
Returns this vector's angle with respect to the positive X axis, or [code](1, 0)[/code] vector, in radians.
|
Returns this vector's angle with respect to the positive X axis, or [code](1, 0)[/code] vector, in radians.
|
||||||
For example, [code]Vector2.RIGHT.angle()[/code] will return zero, [code]Vector2.DOWN.angle()[/code] will return [code]PI / 2[/code] (a quarter turn, or 90 degrees), and [code]Vector2(1, -1).angle()[/code] will return [code]-PI / 4[/code] (a negative eighth turn, or -45 degrees).
|
For example, [code]Vector2.RIGHT.angle()[/code] will return zero, [code]Vector2.DOWN.angle()[/code] will return [code]PI / 2[/code] (a quarter turn, or 90 degrees), and [code]Vector2(1, -1).angle()[/code] will return [code]-PI / 4[/code] (a negative eighth turn, or -45 degrees).
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/vector2_angle.png]Illustration of the returned angle.[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/vector2_angle.png]Illustration of the returned angle.[/url]
|
||||||
Equivalent to the result of [method @GlobalScope.atan2] when called with the vector's [member y] and [member x] as parameters: [code]atan2(y, x)[/code].
|
Equivalent to the result of [method @GlobalScope.atan2] when called with the vector's [member y] and [member x] as parameters: [code]atan2(y, x)[/code].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
|
@ -68,7 +68,7 @@
|
||||||
<param index="0" name="to" type="Vector2" />
|
<param index="0" name="to" type="Vector2" />
|
||||||
<description>
|
<description>
|
||||||
Returns the angle to the given vector, in radians.
|
Returns the angle to the given vector, in radians.
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/vector2_angle_to.png]Illustration of the returned angle.[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/vector2_angle_to.png]Illustration of the returned angle.[/url]
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="angle_to_point" qualifiers="const">
|
<method name="angle_to_point" qualifiers="const">
|
||||||
|
@ -77,7 +77,7 @@
|
||||||
<description>
|
<description>
|
||||||
Returns the angle between the line connecting the two points and the X axis, in radians.
|
Returns the angle between the line connecting the two points and the X axis, in radians.
|
||||||
[code]a.angle_to_point(b)[/code] is equivalent of doing [code](b - a).angle()[/code].
|
[code]a.angle_to_point(b)[/code] is equivalent of doing [code](b - a).angle()[/code].
|
||||||
[url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/vector2_angle_to_point.png]Illustration of the returned angle.[/url]
|
[url=https://raw.githubusercontent.com/godotengine/godot-docs/4.1/img/vector2_angle_to_point.png]Illustration of the returned angle.[/url]
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="aspect" qualifiers="const">
|
<method name="aspect" qualifiers="const">
|
||||||
|
|
Loading…
Reference in New Issue