parent
aca6495a07
commit
bca8c3af6b
21 changed files with 237 additions and 13 deletions
@ -0,0 +1,8 @@ |
||||
fileFormatVersion: 2 |
||||
guid: cf0168c8ec1f9304c9872577b1e6abdf |
||||
folderAsset: yes |
||||
DefaultImporter: |
||||
externalObjects: {} |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
@ -0,0 +1,8 @@ |
||||
fileFormatVersion: 2 |
||||
guid: 23ebabfc8f40d2c4689dc4ec9a5786d5 |
||||
folderAsset: yes |
||||
DefaultImporter: |
||||
externalObjects: {} |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
@ -0,0 +1,8 @@ |
||||
fileFormatVersion: 2 |
||||
guid: 73ee98eea19fa9b42b9c7990a8161d56 |
||||
folderAsset: yes |
||||
DefaultImporter: |
||||
externalObjects: {} |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
@ -0,0 +1,27 @@ |
||||
%YAML 1.1 |
||||
%TAG !u! tag:unity3d.com,2011: |
||||
--- !u!114 &11400000 |
||||
MonoBehaviour: |
||||
m_ObjectHideFlags: 0 |
||||
m_CorrespondingSourceObject: {fileID: 0} |
||||
m_PrefabInstance: {fileID: 0} |
||||
m_PrefabAsset: {fileID: 0} |
||||
m_GameObject: {fileID: 0} |
||||
m_Enabled: 1 |
||||
m_EditorHideFlags: 0 |
||||
m_Script: {fileID: 11500000, guid: cde084f079a7426daa86ed86cb80ed1b, type: 3} |
||||
m_Name: MathEditor |
||||
m_EditorClassIdentifier: |
||||
nodeData: |
||||
rid: -2 |
||||
nodePos: |
||||
serializedVersion: 2 |
||||
x: 0 |
||||
y: 0 |
||||
width: 0 |
||||
height: 0 |
||||
references: |
||||
version: 2 |
||||
RefIds: |
||||
- rid: -2 |
||||
type: {class: , ns: , asm: } |
@ -0,0 +1,8 @@ |
||||
fileFormatVersion: 2 |
||||
guid: acb7b8ebcdf5f4f40bccf1e405c94da3 |
||||
NativeFormatImporter: |
||||
externalObjects: {} |
||||
mainObjectFileID: 11400000 |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
@ -0,0 +1,22 @@ |
||||
using TNode.Editor; |
||||
using UnityEditor; |
||||
using UnityEditor.Callbacks; |
||||
using UnityEditor.Experimental.GraphView; |
||||
using UnityEngine; |
||||
using UnityEngine.UIElements; |
||||
using System; |
||||
public class MathEditor : GraphEditor<MathGraph>{ |
||||
[OnOpenAsset] |
||||
public static bool OnOpenAsset(int instanceID, int line){ |
||||
var graph = EditorUtility.InstanceIDToObject(instanceID) as MathGraph; |
||||
if (graph != null) |
||||
{ |
||||
var wnd = GetWindow<MathEditor>(); |
||||
wnd.titleContent = new GUIContent("MathGraph Editor"); |
||||
wnd.CreateGUI(); |
||||
wnd._graphView.Data = graph; |
||||
return true; |
||||
} |
||||
return false; |
||||
} |
||||
} |
@ -0,0 +1,14 @@ |
||||
fileFormatVersion: 2 |
||||
guid: c9041cb574597424fa4124edc3f99af1 |
||||
MonoImporter: |
||||
externalObjects: {} |
||||
serializedVersion: 2 |
||||
defaultReferences: |
||||
- m_ViewDataDictionary: {instanceID: 0} |
||||
- mVisualTreeAsset: {fileID: 9197481963319205126, guid: b67f6dcbe2361b649ad2b7845207321b, type: 3} |
||||
- nodeEditorData: {fileID: 11400000, guid: acb7b8ebcdf5f4f40bccf1e405c94da3, type: 2} |
||||
executionOrder: 0 |
||||
icon: {instanceID: 0} |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
@ -0,0 +1,9 @@ |
||||
using TNode.Models; |
||||
using TNode.Attribute; |
||||
using TNode.Editor.BaseViews; |
||||
[NodeComponent] |
||||
public class MathGraphView : DataGraphView<MathGraph>{ |
||||
|
||||
|
||||
|
||||
} |
@ -0,0 +1,11 @@ |
||||
fileFormatVersion: 2 |
||||
guid: 7f4d84b648626d24eb29bfeb81c85e3f |
||||
MonoImporter: |
||||
externalObjects: {} |
||||
serializedVersion: 2 |
||||
defaultReferences: [] |
||||
executionOrder: 0 |
||||
icon: {instanceID: 0} |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
@ -0,0 +1,9 @@ |
||||
using TNode.Models; |
||||
using UnityEngine; |
||||
using UnityEditor; |
||||
using System; |
||||
[CreateAssetMenu(fileName = "New MathGraph", menuName = "TNode/MathGraph")] |
||||
[Serializable] |
||||
public class MathGraph : GraphData{ |
||||
|
||||
} |
@ -0,0 +1,11 @@ |
||||
fileFormatVersion: 2 |
||||
guid: 73baeb2c71a23da4ca06e3e3e52d5a78 |
||||
MonoImporter: |
||||
externalObjects: {} |
||||
serializedVersion: 2 |
||||
defaultReferences: [] |
||||
executionOrder: 0 |
||||
icon: {instanceID: 0} |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
@ -0,0 +1,23 @@ |
||||
%YAML 1.1 |
||||
%TAG !u! tag:unity3d.com,2011: |
||||
--- !u!114 &11400000 |
||||
MonoBehaviour: |
||||
m_ObjectHideFlags: 0 |
||||
m_CorrespondingSourceObject: {fileID: 0} |
||||
m_PrefabInstance: {fileID: 0} |
||||
m_PrefabAsset: {fileID: 0} |
||||
m_GameObject: {fileID: 0} |
||||
m_Enabled: 1 |
||||
m_EditorHideFlags: 0 |
||||
m_Script: {fileID: 11500000, guid: 73baeb2c71a23da4ca06e3e3e52d5a78, type: 3} |
||||
m_Name: New MathGraph |
||||
m_EditorClassIdentifier: |
||||
nodes: [] |
||||
nodeLinks: [] |
||||
entryNode: |
||||
rid: -2 |
||||
references: |
||||
version: 2 |
||||
RefIds: |
||||
- rid: -2 |
||||
type: {class: , ns: , asm: } |
@ -0,0 +1,8 @@ |
||||
fileFormatVersion: 2 |
||||
guid: 4b23c513fb78ea44b8a11a0bf7c8479e |
||||
NativeFormatImporter: |
||||
externalObjects: {} |
||||
mainObjectFileID: 11400000 |
||||
userData: |
||||
assetBundleName: |
||||
assetBundleVariant: |
Loading…
Reference in new issue