Answers for "how to add gravity without rb in unity"

C#
0

how to add gravity without rb in unity

public float gravity;
Vector3 velocity;
public CharacterController controller;
void Update()
{
	velocity.y += gravity * Time.deltaTime;
    controller.Move(velocity * Time.deltaTime);
}
Posted by: Guest on August-09-2021

C# Answers by Framework

Browse Popular Code Answers by Language