for some reason the camera only starts to jitter when I move left or right
void FixedUpdate()
{
follow();
}
void follow()
{
Vector3 playerPos = playerpos.position + offset;
Vector3 smoothpos = Vector3.Lerp(transform.position,playerPos,smooth*Time.deltaTime);
camchild.transform.parent = null;
transform.position=smoothpos;
}