Exemplo n.º 1
0
        private NodeBaseInspector GetBaseInspector(NodeValue nodeValue)
        {
            NodeBaseInspector inspector = null;

            if (!_inspectorDic.TryGetValue((NODE_TYPE)nodeValue.NodeType, out inspector))
            {
                inspector = nodeCompositeInspector;
            }
            inspector.SetNodeValue(nodeValue);
            return(inspector);
        }
Exemplo n.º 2
0
        public void Draw(NodeValue nodeValue)
        {
            if (null == nodeValue)
            {
                EditorGUILayout.LabelField("未选择节点");
                return;
            }

            NodeBaseInspector nodeBaseInspector = GetBaseInspector(nodeValue);

            GUI.enabled = !BehaviorDataController.Instance.CurrentOpenConfigSubTree();
            EditorGUILayout.BeginVertical("box");
            {
                nodeBaseInspector.Draw();
            }
            EditorGUILayout.EndVertical();

            ParentInfo();
        }