void Start() { m_ToolMenu = instantiateMenuUI(rayOrigin, m_MenuPrefab); m_connectMenu = m_ToolMenu.GetComponent <ZodiacConnectMenu> (); this.ConnectInterfaces(m_connectMenu, rayOrigin); m_connectMenu.fire = m_zodiacConnector.Fire; m_zodiacConnector = Zodiac.GetZodiacRoot().GetComponent <ZodiacConnector> (); }
protected override void OnGUI() { base.OnGUI(); if (zodiacConnector == null) { zodiacConnector = Zodiac.GetZodiacRoot().gameObject.GetComponent <ZodiacConnector> (); } zodiacConnector.enabled = EditorGUILayout.Toggle("Enabled", zodiacConnector.enabled); if (!zodiacConnector.enabled || !zodiacConnector) { return; } drawContext(); drawSelected(); }
public void UpdateContext(ZodiacConnector connector) { connectContext.text = connector.selectedContextLabel; fireContext.text = connector.fireContextLabel; }
protected override void OnEnable() { zodiacConnector = Zodiac.GetZodiacRoot().gameObject.GetComponent <ZodiacConnector> (); base.OnEnable(); }