瀏覽代碼

Merge pull request #10983 from JRahmatiNL/patch-1

Use SpeedScale in Player.cs in part 9 of 3d tutorial
Matthew 3 月之前
父節點
當前提交
29991b63a1
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      getting_started/first_3d_game/09.adding_animations.rst

+ 2 - 2
getting_started/first_3d_game/09.adding_animations.rst

@@ -451,11 +451,11 @@ Here's the *Player* script.
                 direction = direction.Normalized();
                 // Setting the basis property will affect the rotation of the node.
                 GetNode<Node3D>("Pivot").Basis = Basis.LookingAt(direction);
-                GetNode<AnimationPlayer>("AnimationPlayer").PlaybackSpeed = 4;
+                GetNode<AnimationPlayer>("AnimationPlayer").SpeedScale = 4;
             }
             else
             {
-                GetNode<AnimationPlayer>("AnimationPlayer").PlaybackSpeed = 1;
+                GetNode<AnimationPlayer>("AnimationPlayer").SpeedScale = 1;
             }
 
             // Ground velocity