Skip to content

Commit a60ab49

Browse files
committed
Fix some forgotten lowercase x/y/z
1 parent a6411c7 commit a60ab49

File tree

5 files changed

+14
-10
lines changed

5 files changed

+14
-10
lines changed

getting_started/first_3d_game/09.adding_animations.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,7 @@ Here's the *Player* script.
459459
// Jumping.
460460
if (IsOnFloor() && Input.IsActionJustPressed("jump"))
461461
{
462-
_targetVelocity.y += JumpImpulse;
462+
_targetVelocity.Y += JumpImpulse;
463463
}
464464

465465
// Iterate through all collisions that occurred this frame.

tutorials/3d/using_transforms.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,13 +158,17 @@ It is possible to rotate a transform, either by multiplying its basis by another
158158

159159
.. code-tab:: csharp
160160

161+
Transform3D transform = Transform;
161162
Vector3 axis = new Vector3(1, 0, 0); // Or Vector3.Right
162163
float rotationAmount = 0.1f;
164+
163165
// Rotate the transform around the X axis by 0.1 radians.
164166
transform.Basis = new Basis(axis, rotationAmount) * transform.Basis;
165167
// shortened
166168
transform.Basis = transform.Basis.Rotated(axis, rotationAmount);
167169

170+
Transform = transform;
171+
168172
A method in Node3D simplifies this:
169173

170174
.. tabs::

tutorials/math/matrices_and_transforms.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,8 @@ To do this in code, we multiply each of the vectors:
8585

8686
Transform2D t = Transform2D.Identity;
8787
// Scale
88-
t.x *= 2;
89-
t.y *= 2;
88+
t.X *= 2;
89+
t.Y *= 2;
9090
Transform = t; // Change the node's transform to what we calculated.
9191
9292
If we wanted to return it to its original scale, we can multiply
@@ -324,7 +324,7 @@ As an example, let's set Y to (1, 1):
324324

325325
Transform2D t = Transform2D.Identity;
326326
// Shear by setting Y to (1, 1)
327-
t.y = Vector2.One;
327+
t.Y = Vector2.One;
328328
Transform = t; // Change the node's transform to what we calculated.
329329

330330
.. note:: You can't set the raw values of a Transform2D in the editor,

tutorials/math/vectors_advanced.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -189,9 +189,9 @@ degrees to either side:
189189
// Calculate vector from `a` to `b`.
190190
var dvec = pointA.DirectionTo(pointB);
191191
// Rotate 90 degrees.
192-
var normal = new Vector2(dvec.y, -dvec.x);
192+
var normal = new Vector2(dvec.Y, -dvec.X);
193193
// Alternatively (depending the desired side of the normal):
194-
// var normal = new Vector2(-dvec.y, dvec.x);
194+
// var normal = new Vector2(-dvec.Y, dvec.X);
195195

196196
The rest is the same as the previous example. Either point_a or
197197
point_b will work, as they are in the same plane:

tutorials/ui/size_and_anchors.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,10 +93,10 @@ a TextureRect can be centered in its parent:
9393

9494
var textureSize = rect.Texture.GetSize();
9595

96-
rect.OffsetLeft = -textureSize.x / 2;
97-
rect.OffsetRight = textureSize.x / 2;
98-
rect.OffsetTop = -textureSize.y / 2;
99-
rect.OffsetBottom = textureSize.y / 2;
96+
rect.OffsetLeft = -textureSize.X / 2;
97+
rect.OffsetRight = textureSize.X / 2;
98+
rect.OffsetTop = -textureSize.Y / 2;
99+
rect.OffsetBottom = textureSize.Y / 2;
100100
AddChild(rect);
101101

102102
Setting each anchor to 0.5 moves the reference point for the margins to

0 commit comments

Comments
 (0)