toggle being a child

So I want to be able to be stuck to my character, unless I hit y which would let me roam about the map.

Sorry, i didn’t mean to enter that.

I know what to do about panning, and the toggleing Y itself. What i need to know how to attach and detach the camera from the gameobject.…