public void ReturnToBigfootBack() { distance = Vector3.Distance(this.transform.position, tpCam.transform.position); startPos = this.transform.position; startRotation = this.transform.rotation; setCameraBackToMain = true; state = CameraAnimState.AnimatingBehindBigfoot; }
public void AnimateInFrontOfBigfoot() { distance = Vector3.Distance(tpCam.transform.position, animationCameraPos.transform.position); this.transform.position = tpCam.transform.position; startPos = tpCam.transform.position; startRotation = this.transform.rotation; SetCam(1); setCameraBackToMain = false; state = CameraAnimState.AnimatingInFrontOfBigfoot; }
public void RotateTowards() { if (distance > 1) { Vector3 lookAtPos = bigfoot.transform.position + rotationOffset; this.transform.LookAt(lookAtPos); } else { if (setCameraBackToMain) { SetCam(0); } state = CameraAnimState.None; } }