unity make a gameobject not dontdestroyonload code example Example: dontdestroyonload unity DontDestroyOnLoad(this.gameObject);