protected override void KGFAwake() { base.KGFAwake(); if (itsInstance == null) { itsInstance = this; } else { UnityEngine.Object.Destroy(this); } KGFAccessor.RegisterAddEvent <KGFICustomGUI>(OnCustomGuiChanged); KGFAccessor.RegisterRemoveEvent <KGFICustomGUI>(OnCustomGuiChanged); UpdateInternalList(); }
protected override void KGFAwake() { itsGUIs = KGFAccessor.GetObjects <KGFIGui2D>(); KGFAccessor.RegisterAddEvent <KGFIGui2D>(OnRegisterKGFIGui2D); KGFAccessor.RegisterRemoveEvent <KGFIGui2D>(OnUnregisterKGFIGui2D); }