Answers for "C# sprint key"

C#
0

C# sprint key

if (Input.GetKey("left shift")){ // If Player Presses Shift Key
	Sprint = 2f; // Sprint Double Speed
} else {
	Sprint = 1f; // Disable Sprint
}

// Move Player
controller.Move(move * speed * Sprint * Time.deltaTime); 
// Move is your Player Move Variable
Posted by: Guest on June-15-2020

C# Answers by Framework

Browse Popular Code Answers by Language