I made a capsule and added a rigidbody component. I hit play and it collides with the box below it. However, when I add this to the C# script I get an error
public Rigidbody rb = GetComponent();
Assets/PlayerMove.cs(10,24): error CS0236: A field initializer cannot reference the nonstatic field, method, or property `UnityEngine.Component.GetComponent<UnityEngine.Rigidbody>()’