public static ResolutionAdapter resolutionAdapter; //Singleton void Awake() { if (resolutionAdapter == null) { DontDestroyOnLoad(gameObject); // Persistent between scenes resolutionAdapter = this; // Additional initialisation } else if (resolutionAdapter != this) { Destroy(gameObject); } }
public RResolutionAdapt(ResolutionAdapter.Resolution res) { this.resolution = res; }