public void Deactivate() { StopListeners(); Reset(); UIManager.UI.destroySHP(gameObject); linked_gobject = null; assoc_shp = null; }
public void Deactivate() { StopListeners (); Reset (); UIManager.UI.destroySHP (gameObject); linked_gobject = null; assoc_shp = null; }
public void destroySHP(GameObject anchor) { if (anchor.GetComponent <GRObject> ().assoc_shp != null) { SmallHoveringPanel shp = anchor.GetComponent <GRObject> ().assoc_shp; anchor.GetComponent <GRObject> ().assoc_shp = null; Destroy(shp.gameObject); } }
public SmallHoveringPanel createSHP(GameObject anchor) { GameObject panelObj = Instantiate(SmallHoveringPanel_Prefab) as GameObject; panelObj.transform.SetParent(canvas.transform); SmallHoveringPanel smh = panelObj.GetComponent <SmallHoveringPanel> (); smh.Init(anchor, this); anchor.GetComponent <GRObject> ().assoc_shp = smh; return(smh); }