My camera flip with the player, help

My camera flip with the player because I have a Flip script on my player and the camera is the son of the player and is doing flip along with the player, is there a way to solve this and make only my player flip and not the camera?

Child object always inherits the parent’s movement/rotation in unity.

Make the camera a separate object and make a script for it.

Make camera set it’s transform.position.x and transform.position.y to those of the player in Update() function. (If your project is a 2d platformer or a sidescroller. Script logic could be different otherwise)

Alternatively learn how to use Cinemachine tool. It’s quite easy to make it do all you could want from a camera and there are some great tutorials for it online.