/// <summary> /// On Awake, make sure that all properties have been set up properly. /// </summary> void Awake() { if (fpFreezePlayer == null) { Debug.LogError("You must assign FPFreezePlayer to " + name); enabled = false; } if (fpInventory == null) { Debug.LogError("You must assign vp_Inventory to " + name); enabled = false; } guiRoot = GetComponentInChildren <GUIRoot>(); if (guiRoot == null) { Debug.LogError("No GUIRoot found under " + name); enabled = false; } else { guiRoot.gameObject.SetActive(false); } if (weaponPanels.Length <= 0) { Debug.LogError("You must assign at least one weapon panel to " + name); enabled = false; } }
void Awake() { GUIRoot.instance = this; }
/// <summary> /// Helper function that figures out the pixel size adjustment for the specified game object. /// </summary> static public float GetPixelSizeAdjustment(GameObject go) { GUIRoot root = NJGTools.FindInParents <GUIRoot>(go); return((root != null) ? root.pixelSizeAdjustment : 1f); }
void Awake() { __instance = this; }
void Awake() { guiRoot = GetComponent <GUIRoot>(); }
internal void SetGuiRoot(GUIRoot gUIRoot) { this._guiroot = gUIRoot; }
void Awake() { __instance = this; }
internal void SetDependencies(GUIRoot gUIRoot) { this.guiRoot = gUIRoot; }