void Start() { if (! anchor9) anchor9 = GameHUD.mainLayer.anchor9; m_HUD = anchor9.AddPrf(prefab, anchor); m_HUD.transform.localPosition = offset; if (destroyAfterCreate) Destroy(gameObject); }
void Awake() { if (!camera_) { camera_ = camera; } if (!anchor9) { anchor9 = GetComponent <UIAnchor9>(); } GameHUD.mainLayer = this; }
void Start() { if (!anchor9) { anchor9 = GameHUD.mainLayer.anchor9; } m_HUD = anchor9.AddPrf(prefab, anchor); m_HUD.transform.localPosition = offset; if (destroyAfterCreate) { Destroy(gameObject); } }
void Awake() { if (!camera_) camera_ = camera; if (!anchor9) anchor9 = GetComponent<UIAnchor9>(); GameHUD.mainLayer = this; }