Example #1
0
        public override void OnInspectorGUI()
        {
            base.OnInspectorGUI();

            GUILayout.BeginHorizontal();

            GUILayout.Label("Transitions", GUILayout.MaxWidth(80f));

            DisplayAddTransition("new-t");

            GUILayout.EndHorizontal();

            Dictionary <string, Transition[]> transitionsById =
                TransitionUtils.FindAndGroupTransitions(this.panel.transform);

            foreach (KeyValuePair <string, Transition[]> t in transitionsById)
            {
                DisplayTransitionType(t.Key, t.Value);
            }

            DisplayIfMissing(transitionsById, PanelTransition.IN.name, PanelTransition.OUT.name);

            GUI.contentColor = Color.white;

            if (m_doOrganizeInspector)
            {
                m_doOrganizeInspector = false;
                OrganizeInspector();
            }
        }
Example #2
0
 public bool GetTransitions(string name, out Transition[] tlist)
 {
     if (m_transitionsByName == null)
     {
         m_transitionsByName = TransitionUtils.FindAndGroupTransitions(this.transform);
     }
     return(m_transitionsByName.TryGetValue(name, out tlist));
 }