From 2768930e01ebb3d32508857f2479ef37dc1c5ae7 Mon Sep 17 00:00:00 2001 From: haitem Date: Sat, 29 Jan 2022 21:36:42 +0100 Subject: [PATCH] Repair side move --- Assets/Scripts/PlayerController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Assets/Scripts/PlayerController.cs b/Assets/Scripts/PlayerController.cs index d1c78dc..63763fe 100644 --- a/Assets/Scripts/PlayerController.cs +++ b/Assets/Scripts/PlayerController.cs @@ -82,7 +82,7 @@ public class PlayerController : MonoBehaviour } float curSpeedX = canMove ? (currentSpeed + modifier) : 0; - float curSpeedY = canMove ? (speed + modifier) * Input.GetAxis("Horizontal") : 0; + float curSpeedY = canMove ? (currentSpeed + modifier) * Input.GetAxis("Horizontal") : 0; moveDirection = (platformForward * curSpeedX * Time.deltaTime) + (transform.right * curSpeedY * Time.deltaTime);