I want the player to be able to throw an object (rigidbody). The code below instantiates the object at player/camera position, but then doesn’t “throw” it - not sure what I’m doing wrong. Thanks/
private float forceLevel = 500f;
[SerializeField]
private GameObject throwingSphere;
void Update()
{
if (Input.GetMouseButtonDown(0))
{
Instantiate(throwingSphere, transform.position, Quaternion.identity);
var rigBdy = throwingSphere.GetComponent<Rigidbody>();
}
}