diff options
Diffstat (limited to 'doc/classes/Transform2D.xml')
-rw-r--r-- | doc/classes/Transform2D.xml | 51 |
1 files changed, 44 insertions, 7 deletions
diff --git a/doc/classes/Transform2D.xml b/doc/classes/Transform2D.xml index 6ae7fbcf79..4f9b59c188 100644 --- a/doc/classes/Transform2D.xml +++ b/doc/classes/Transform2D.xml @@ -18,7 +18,7 @@ <return type="Transform2D"> </return> <description> - Constructs a default-initialized [Transform] set to [constant IDENTITY]. + Constructs a default-initialized [Transform2D] set to [constant IDENTITY]. </description> </method> <method name="Transform2D" qualifiers="constructor"> @@ -129,6 +129,16 @@ Returns [code]true[/code] if this transform and [code]transform[/code] are approximately equal, by calling [code]is_equal_approx[/code] on each component. </description> </method> + <method name="looking_at" qualifiers="const"> + <return type="Transform2D"> + </return> + <argument index="0" name="target" type="Vector2" default="Transform2D(1, 0, 0, 1, 0, 0)"> + </argument> + <description> + Returns a copy of the transform rotated such that it's rotation on the X-axis points towards the [code]target[/code] position. + Operations take place in global space. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> @@ -169,6 +179,24 @@ <description> </description> </method> + <method name="operator *" qualifiers="operator"> + <return type="Transform2D"> + </return> + <argument index="0" name="right" type="float"> + </argument> + <description> + This operator multiplies all components of the [Transform2D], including the origin vector, which scales it uniformly. + </description> + </method> + <method name="operator *" qualifiers="operator"> + <return type="Transform2D"> + </return> + <argument index="0" name="right" type="int"> + </argument> + <description> + This operator multiplies all components of the [Transform2D], including the origin vector, which scales it uniformly. + </description> + </method> <method name="operator ==" qualifiers="operator"> <return type="bool"> </return> @@ -210,6 +238,15 @@ Scales the transform by the given scale factor, using matrix multiplication. </description> </method> + <method name="set_rotation"> + <return type="void"> + </return> + <argument index="0" name="rotation" type="float"> + </argument> + <description> + Sets the transform's rotation (in radians). + </description> + </method> <method name="translated" qualifiers="const"> <return type="Transform2D"> </return> @@ -222,24 +259,24 @@ </method> </methods> <members> - <member name="origin" type="Vector2" setter="" getter="" default="Vector2( 0, 0 )"> + <member name="origin" type="Vector2" setter="" getter="" default="Vector2(0, 0)"> The origin vector (column 2, the third column). Equivalent to array index [code]2[/code]. The origin vector represents translation. </member> - <member name="x" type="Vector2" setter="" getter="" default="Vector2( 1, 0 )"> + <member name="x" type="Vector2" setter="" getter="" default="Vector2(1, 0)"> The basis matrix's X vector (column 0). Equivalent to array index [code]0[/code]. </member> - <member name="y" type="Vector2" setter="" getter="" default="Vector2( 0, 1 )"> + <member name="y" type="Vector2" setter="" getter="" default="Vector2(0, 1)"> The basis matrix's Y vector (column 1). Equivalent to array index [code]1[/code]. </member> </members> <constants> - <constant name="IDENTITY" value="Transform2D( 1, 0, 0, 1, 0, 0 )"> + <constant name="IDENTITY" value="Transform2D(1, 0, 0, 1, 0, 0)"> The identity [Transform2D] with no translation, rotation or scaling applied. When applied to other data structures, [constant IDENTITY] performs no transformation. </constant> - <constant name="FLIP_X" value="Transform2D( -1, 0, 0, 1, 0, 0 )"> + <constant name="FLIP_X" value="Transform2D(-1, 0, 0, 1, 0, 0)"> The [Transform2D] that will flip something along the X axis. </constant> - <constant name="FLIP_Y" value="Transform2D( 1, 0, 0, -1, 0, 0 )"> + <constant name="FLIP_Y" value="Transform2D(1, 0, 0, -1, 0, 0)"> The [Transform2D] that will flip something along the Y axis. </constant> </constants> |