Merge pull request #43 from taoria/work-in-progress

refactor:namespace
main
taoria 3 years ago committed by GitHub
commit 71548cf5bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 9
      GraphCreator/Runtime/Blackboard/GraphMetaBlackboard.cs
  2. 26
      Samples/Editor/HelloEditor.cs
  3. 6
      Samples/New Animator Controller.controller.meta
  4. 2
      Samples/TestScene.unity.meta
  5. 0
      TNodeCore/GraphCreator.meta
  6. 0
      TNodeCore/GraphCreator/Editor.meta
  7. 2
      TNodeCore/GraphCreator/Editor/GraphCreator.cs
  8. 0
      TNodeCore/GraphCreator/Editor/GraphCreator.cs.meta
  9. 0
      TNodeCore/GraphCreator/Runtime.meta
  10. 0
      TNodeCore/GraphCreator/Runtime/Blackboard.meta
  11. 8
      TNodeCore/GraphCreator/Runtime/Blackboard/GraphMetaBlackboard.cs
  12. 0
      TNodeCore/GraphCreator/Runtime/Blackboard/GraphMetaBlackboard.cs.meta
  13. 0
      TNodeCore/GraphCreator/Runtime/GraphMetaNode.cs
  14. 0
      TNodeCore/GraphCreator/Runtime/GraphMetaNode.cs.meta
  15. 0
      TNodeCore/GraphCreator/Runtime/MetaGraph.cs
  16. 0
      TNodeCore/GraphCreator/Runtime/MetaGraph.cs.meta
  17. 0
      TNodeCore/GraphCreator/Runtime/Nodes.meta
  18. 3
      TNodeCore/GraphCreator/Runtime/Nodes/GraphMetaNode.cs
  19. 0
      TNodeCore/GraphCreator/Runtime/Nodes/GraphMetaNode.cs.meta
  20. 10
      TNodeGraphViewImpl/Editor/Cache/NodeEditorExtensions.cs
  21. 2
      TNodeGraphViewImpl/Editor/GraphBlackboard/BlackboardDataEntry.cs
  22. 6
      TNodeGraphViewImpl/Editor/GraphBlackboard/BlackboardField.cs
  23. 2
      TNodeGraphViewImpl/Editor/GraphBlackboard/BlackboardProperty/BlackboardProperty.cs
  24. 4
      TNodeGraphViewImpl/Editor/GraphBlackboard/DefaultGraphBlackboardView.cs
  25. 2
      TNodeGraphViewImpl/Editor/GraphBlackboard/GraphBlackboardPropertyField.cs
  26. 2
      TNodeGraphViewImpl/Editor/GraphBlackboard/GraphBlackboardView.cs
  27. 8
      TNodeGraphViewImpl/Editor/Inspector/NodeInspector.cs
  28. 2
      TNodeGraphViewImpl/Editor/Inspector/NodeInspectorInNode.cs
  29. 20
      TNodeGraphViewImpl/Editor/NodeGraphView/DataGraphView.cs
  30. 7
      TNodeGraphViewImpl/Editor/NodeGraphView/SimpleGraphSubWindow.cs
  31. 2
      TNodeGraphViewImpl/Editor/NodeViews/DefaultNodeView.cs
  32. 2
      TNodeGraphViewImpl/Editor/NodeViews/DragNodeView.cs
  33. 6
      TNodeGraphViewImpl/Editor/NodeViews/NodeView.cs
  34. 2
      TNodeGraphViewImpl/Editor/Placemats/PlacematView.cs
  35. 4
      TNodeGraphViewImpl/Editor/Ports/CustomPort.cs
  36. 3
      TNodeGraphViewImpl/Editor/Search/BlackboardSearchWindowProvider.cs
  37. 4
      TNodeGraphViewImpl/Editor/Search/NodeSearchWindowProvider.cs
  38. 2
      TNodeGtfImpl/Editor/BaseView.cs
  39. 5
      TNodeGtfImpl/GTFReference.asmref.meta

@ -1,9 +0,0 @@
using TNodeCore.Editor.EditorPersistence;
using TNodeCore.Runtime.Models;
namespace TNode.GraphCreator.Runtime.Blackboard{
public class GraphMetaBlackboard:BlackboardData{
}
}

@ -1,20 +1,21 @@
using Samples;
using TNodeCore.Editor;
using UnityEditor;
using UnityEditor.Callbacks;
using UnityEngine;
using TNodeCore.Editor;
public class HelloEditor : GraphEditor<HelloGraph>{
namespace Samples.Editor{
public class HelloEditor : GraphEditor<HelloGraph>{
[OnOpenAsset]
public static bool OnOpenAsset(int instanceID, int line){
var graph = EditorUtility.InstanceIDToObject(instanceID) as HelloGraph;
if (graph != null) {
var wnd = GetWindow<HelloEditor>();
wnd.titleContent = new GUIContent("HelloGraph Editor");
wnd.Show();
wnd.SetupNonRuntime(graph);
return true;
}
return false;
var graph = EditorUtility.InstanceIDToObject(instanceID) as HelloGraph;
if (graph != null) {
var wnd = GetWindow<HelloEditor>();
wnd.titleContent = new GUIContent("HelloGraph Editor");
wnd.Show();
wnd.SetupNonRuntime(graph);
return true;
}
return false;
}
[MenuItem("Window/HelloEditor")]
public static void ShowWindow(){
@ -23,4 +24,5 @@ public class HelloEditor : GraphEditor<HelloGraph>{
res.Show();
}
}
}

@ -1,8 +1,8 @@
fileFormatVersion: 2
guid: f54d1bd14bd3ca042bd867b519fee8cc
folderAsset: yes
DefaultImporter:
guid: 416b2146595ee9245be40d8a34aff436
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 9100000
userData:
assetBundleName:
assetBundleVariant:

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 2cda990e2423bbf4892e6590ba056729
guid: 49e3a9e72efd1a847a568e8b12744466
DefaultImporter:
externalObjects: {}
userData:

@ -1,7 +1,7 @@
using TNode.GraphCreator.Runtime;
using TNodeCore.Editor;
namespace TNode.GraphCreator.Editor{
namespace TNodeCore.GraphCreator.Editor{
public class GraphCreator:GraphEditor<MetaGraph>{
}

@ -0,0 +1,8 @@
using TNodeCore.Runtime.Models;
namespace TNodeCore.GraphCreator.Runtime.Blackboard{
public class GraphMetaBlackboard:BlackboardData{
}
}

@ -1,8 +1,9 @@
using System;
using TNode.GraphCreator.Runtime;
using TNodeCore.Runtime.Attributes;
using TNodeCore.Runtime.Models;
namespace TNode.GraphCreator.Runtime.Nodes{
namespace TNodeCore.GraphCreator.Runtime.Nodes{
namespace TNode.GraphCreator.Runtime{

@ -4,17 +4,15 @@ using System.Linq;
using System.Reflection;
using TNode.TNodeCore.Editor.Blackboard;
using TNode.TNodeCore.Editor.EditorPersistence;
using TNode.TNodeGraphViewImpl.Editor.GraphBlackboard;
using TNode.TNodeGraphViewImpl.Editor.NodeGraphView;
using TNode.TNodeGraphViewImpl.Editor.NodeViews;
using TNodeCore.Editor.EditorPersistence;
using TNodeCore.Editor.NodeGraphView;
using TNodeCore.Runtime.Attributes;
using TNodeCore.Runtime.Models;
using TNodeGraphViewImpl.Editor.GraphBlackboard;
using TNodeGraphViewImpl.Editor.NodeGraphView;
using TNodeGraphViewImpl.Editor.NodeViews;
using UnityEditor;
using UnityEngine;
namespace TNode.TNodeGraphViewImpl.Editor.Cache{
namespace TNodeGraphViewImpl.Editor.Cache{
/// <summary>
/// Internal singleton class for caching TNode reflection Data.
/// </summary>

@ -5,7 +5,7 @@ using UnityEditor.Experimental.GraphView;
using UnityEngine;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.GraphBlackboard{
namespace TNodeGraphViewImpl.Editor.GraphBlackboard{
public class BlackboardDataEntry:GraphElement{
public Type propertyType;
public string propertyPath;

@ -1,7 +1,7 @@
namespace TNode.TNodeGraphViewImpl.Editor.GraphBlackboard{
namespace TNodeGraphViewImpl.Editor.GraphBlackboard{
public class BlackboardField:UnityEditor.Experimental.GraphView.BlackboardField{
public global::TNode.TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardProperty.BlackboardProperty BlackboardProperty;
public BlackboardField(global::TNode.TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardProperty.BlackboardProperty blackboardProperty):base(null,blackboardProperty.PropertyName,null){
public global::TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardProperty.BlackboardProperty BlackboardProperty;
public BlackboardField(global::TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardProperty.BlackboardProperty blackboardProperty):base(null,blackboardProperty.PropertyName,null){
BlackboardProperty = blackboardProperty;
}
}

@ -1,6 +1,6 @@
using System;
namespace TNode.TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardProperty{
namespace TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardProperty{
public class BlackboardProperty{
public string PropertyName;
public Type PropertyType;

@ -3,17 +3,17 @@ using System.Collections;
using System.Linq;
using System.Reflection;
using TNode.TNodeCore.Editor.Serialization;
using TNode.TNodeGraphViewImpl.Editor.Search;
using TNodeCore.Editor.NodeGraphView;
using TNodeCore.Runtime.Attributes;
using TNodeCore.Runtime.Models;
using TNodeGraphViewImpl.Editor.Search;
using UnityEditor;
using UnityEditor.Experimental.GraphView;
using UnityEditor.UIElements;
using UnityEngine;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.GraphBlackboard{
namespace TNodeGraphViewImpl.Editor.GraphBlackboard{
[ViewComponent]
public class DefaultGraphBlackboardView:GraphBlackboardView<BlackboardData>{

@ -2,7 +2,7 @@
using UnityEditor.UIElements;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.GraphBlackboard{
namespace TNodeGraphViewImpl.Editor.GraphBlackboard{
public class GraphBlackboardPropertyField:PropertyField{
private readonly bool _runtime;

@ -5,7 +5,7 @@ using UnityEditor;
using UnityEditor.Experimental.GraphView;
using UnityEngine;
namespace TNode.TNodeGraphViewImpl.Editor.GraphBlackboard{
namespace TNodeGraphViewImpl.Editor.GraphBlackboard{
/// <summary>
/// Implement this class to create graph black board for specified graph
/// </summary>

@ -1,11 +1,11 @@
using TNode.TNodeGraphViewImpl.Editor.NodeGraphView;
using TNode.TNodeGraphViewImpl.Editor.NodeViews;
using TNodeCore.Runtime.Models;
using TNodeCore.Runtime.Models;
using TNodeGraphViewImpl.Editor.NodeGraphView;
using TNodeGraphViewImpl.Editor.NodeViews;
using UnityEditor.Experimental.GraphView;
using UnityEngine;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.Inspector{
namespace TNodeGraphViewImpl.Editor.Inspector{
public class NodeInspector:SimpleGraphSubWindow{
private NodeData _data;
public NodeData Data{

@ -7,7 +7,7 @@ using UnityEditor;
using UnityEditor.UIElements;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.Inspector{
namespace TNodeGraphViewImpl.Editor.Inspector{
public class NodeInspectorInNode:VisualElement{
private NodeData _data;
public NodeData Data{

@ -7,30 +7,26 @@ using TNode.TNodeCore.Editor.Blackboard;
using TNode.TNodeCore.Editor.CommentView;
using TNode.TNodeCore.Editor.EditorPersistence;
using TNode.TNodeCore.Editor.Models;
using TNode.TNodeGraphViewImpl.Editor.Cache;
using TNode.TNodeGraphViewImpl.Editor.GraphBlackboard;
using TNode.TNodeGraphViewImpl.Editor.Inspector;
using TNode.TNodeGraphViewImpl.Editor.NodeViews;
using TNode.TNodeGraphViewImpl.Editor.Placemats;
using TNode.TNodeGraphViewImpl.Editor.Search;
using TNodeCore.Editor;
using TNodeCore.Editor.EditorPersistence;
using TNodeCore.Editor.NodeGraphView;
using TNodeCore.Editor.Tools.NodeCreator;
using TNodeCore.Runtime.Components;
using TNodeCore.Runtime.Models;
using TNodeCore.Runtime.RuntimeCache;
using TNodeGraphViewImpl.Editor.Cache;
using TNodeGraphViewImpl.Editor.GraphBlackboard;
using TNodeGraphViewImpl.Editor.Inspector;
using TNodeGraphViewImpl.Editor.NodeViews;
using TNodeGraphViewImpl.Editor.Placemats;
using TNodeGraphViewImpl.Editor.Search;
using UnityEditor;
using UnityEditor.Experimental.GraphView;
using UnityEditor.UIElements;
using UnityEngine;
using UnityEngine.UIElements;
using BlackboardField = TNode.TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardField;
using BlackboardField = TNodeGraphViewImpl.Editor.GraphBlackboard.BlackboardField;
using Edge = UnityEditor.Experimental.GraphView.Edge;
namespace TNode.TNodeGraphViewImpl.Editor.NodeGraphView{
namespace TNodeGraphViewImpl.Editor.NodeGraphView{
public class BaseDataGraphView<T>:GraphView,IDataGraphView<T> where T:GraphData{
#region const
public const float RefreshRate = 1f;

@ -1,11 +1,8 @@
using System.Linq;
using TNode.TNodeCore.Editor.EditorPersistence;
using TNodeCore.Editor.EditorPersistence;
using UnityEditor;
using UnityEditor;
using UnityEditor.Experimental.GraphView;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.NodeGraphView{
namespace TNodeGraphViewImpl.Editor.NodeGraphView{
public class SimpleGraphSubWindow:GraphElement{
private readonly Dragger _dragger = new Dragger();

@ -1,6 +1,6 @@
using TNodeCore.Runtime.Models;
namespace TNode.TNodeGraphViewImpl.Editor.NodeViews{
namespace TNodeGraphViewImpl.Editor.NodeViews{
public class DefaultBaseNodeView:BaseNodeView<NodeData>{

@ -7,7 +7,7 @@ using UnityEditor.Experimental.GraphView;
using UnityEngine;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.NodeViews{
namespace TNodeGraphViewImpl.Editor.NodeViews{
[ViewComponent]
public class DragBaseNodeView:BaseNodeView<BlackboardDragNode>{
public DragBaseNodeView() : base(){

@ -2,20 +2,20 @@
using System.Linq;
using System.Reflection;
using TNode.TNodeCore.Editor.Serialization;
using TNode.TNodeGraphViewImpl.Editor.Inspector;
using TNode.TNodeGraphViewImpl.Editor.Ports;
using TNodeCore.Editor.NodeGraphView;
using TNodeCore.Runtime;
using TNodeCore.Runtime.Attributes;
using TNodeCore.Runtime.Attributes.Ports;
using TNodeCore.Runtime.Models;
using TNodeGraphViewImpl.Editor.Inspector;
using TNodeGraphViewImpl.Editor.Ports;
using UnityEditor;
using UnityEditor.Experimental.GraphView;
using UnityEngine;
using UnityEngine.UIElements;
using Direction = UnityEditor.Experimental.GraphView.Direction;
namespace TNode.TNodeGraphViewImpl.Editor.NodeViews{
namespace TNodeGraphViewImpl.Editor.NodeViews{
public abstract class BaseNodeView<T> : Node,INodeView<T> where T:NodeData,new(){
protected T _data;

@ -3,7 +3,7 @@ using UnityEditor.Experimental.GraphView;
using UnityEngine;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.Placemats{
namespace TNodeGraphViewImpl.Editor.Placemats{
public class PlacematView:Placemat{
public PlacematModel PlacematModel{
get => _placematModel;

@ -1,13 +1,13 @@
using System;
using System.Collections.Generic;
using System.Linq;
using TNode.TNodeGraphViewImpl.Editor.NodeViews;
using TNodeCore.Editor.NodeGraphView;
using TNodeCore.Runtime.Models;
using TNodeGraphViewImpl.Editor.NodeViews;
using UnityEditor.Experimental.GraphView;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.Ports{
namespace TNodeGraphViewImpl.Editor.Ports{
public class CustomPort:UnityEditor.Experimental.GraphView.Port{
public CustomPort(Orientation portOrientation, Direction portDirection, Capacity portCapacity, Type type) : base(portOrientation, portDirection, portCapacity, type){
m_EdgeConnector = new EdgeConnector<Edge>(new CustomEdgeConnectorListener());

@ -2,14 +2,13 @@
using System.Collections;
using System.Collections.Generic;
using TNode.TNodeCore.Editor.Blackboard;
using TNode.TNodeGraphViewImpl.Editor.GraphBlackboard;
using TNodeCore.Editor.NodeGraphView;
using UnityEditor;
using UnityEditor.Experimental.GraphView;
using UnityEngine;
using Object = UnityEngine.Object;
namespace TNode.TNodeGraphViewImpl.Editor.Search{
namespace TNodeGraphViewImpl.Editor.Search{
public class BlackboardSearchWindowProvider:ScriptableObject,ISearchWindowProvider{
private Type _graphType;
private IBaseDataGraphView _graphView;

@ -1,16 +1,16 @@
using System;
using System.Collections.Generic;
using System.Linq;
using TNode.TNodeGraphViewImpl.Editor.Cache;
using TNodeCore.Editor.NodeGraphView;
using TNodeCore.Editor.Tools.NodeCreator;
using TNodeCore.Runtime.Models;
using TNodeGraphViewImpl.Editor.Cache;
using UnityEditor;
using UnityEditor.Experimental.GraphView;
using UnityEngine;
using UnityEngine.UIElements;
namespace TNode.TNodeGraphViewImpl.Editor.Search{
namespace TNodeGraphViewImpl.Editor.Search{
public class NodeSearchWindowProvider:ScriptableObject,ISearchWindowProvider{
private Type _graphType;
private GraphView _graphView;

@ -1,5 +1,5 @@
#define UNITY_2020_1_OR_NEWER
namespace TNode.TNodeGtfImpl.Editor{
namespace TNodeGtfImpl.Editor{
public class BaseView{
}

@ -1,7 +1,6 @@
fileFormatVersion: 2
guid: 131a6b21c8605f84396be9f6751fb6e3
folderAsset: yes
DefaultImporter:
guid: de9b4da88084be341822a6bfc1636129
AssemblyDefinitionReferenceImporter:
externalObjects: {}
userData:
assetBundleName:
Loading…
Cancel
Save