void TekYap() { if (ornek != null) { Destroy(gameObject); } else { ornek = this; DontDestroyOnLoad(gameObject); } }
private void Awake() { if (_instance == null) { _instance = this; DontDestroyOnLoad(gameObject); } else { Destroy(gameObject); } }
// Start is called before the first frame update void Start() { pK_Script = GetComponent <PanelKontrol>(); sahneGecis = GameObject.Find("SahneManager").GetComponent <SahneGecis>(); }