void OnGUI() { if (GUI.Button(new Rect(100, 100, 100, 50), "boradcast msg")) { if (m_curController == null || !(m_curController is BroadcastAcotr)) { m_curController = new BroadcastAcotr(); } m_curController.onClick(-1); } if (GUI.Button(new Rect(100, 300, 100, 50), "notify msg")) { if (m_curController == null || !(m_curController is NotifyActor)) { m_curController = new NotifyActor(); } m_curController.onClick(-1); } }
void OnGUI() { if(GUI.Button(new Rect(100,100,100,50),"boradcast msg")) { if(m_curController == null || !(m_curController is BroadcastAcotr)) { m_curController = new BroadcastAcotr(); } m_curController.onClick(-1); } if(GUI.Button(new Rect(100,300,100,50),"notify msg")) { if(m_curController == null || !(m_curController is NotifyActor)) { m_curController = new NotifyActor(); } m_curController.onClick(-1); } }