├── .gitignore ├── .gitmodules ├── Assets ├── Plugins.meta ├── Plugins │ ├── Editor.meta │ ├── Editor │ │ ├── RelationsInspector.meta │ │ └── RelationsInspector │ │ │ ├── BackendUtils.meta │ │ │ ├── Backends.meta │ │ │ ├── Backends │ │ │ ├── AutoBackend.meta │ │ │ ├── AutoBackend │ │ │ │ ├── RIAutoBackend.cs │ │ │ │ ├── RIAutoBackend.cs.meta │ │ │ │ ├── ReflectionUtil.cs │ │ │ │ └── ReflectionUtil.cs.meta │ │ │ ├── HierarchyExample.meta │ │ │ └── HierarchyExample │ │ │ │ ├── SceneHierarchyBackend.cs │ │ │ │ ├── SceneHierarchyBackend.cs.meta │ │ │ │ ├── TagBackend.cs │ │ │ │ └── TagBackend.cs.meta │ │ │ ├── Manual.pdf │ │ │ ├── Manual.pdf.meta │ │ │ ├── Packages.meta │ │ │ ├── Packages │ │ │ ├── AssetReferences.unitypackage │ │ │ ├── AssetReferences.unitypackage.meta │ │ │ ├── DialogueSystem.unitypackage │ │ │ ├── DialogueSystem.unitypackage.meta │ │ │ ├── InventoryMaster.unitypackage │ │ │ ├── InventoryMaster.unitypackage.meta │ │ │ ├── InventoryPro.unitypackage │ │ │ ├── InventoryPro.unitypackage.meta │ │ │ ├── PlayMakerFSMCommunication.unitypackage │ │ │ ├── PlayMakerFSMCommunication.unitypackage.meta │ │ │ ├── ProjectView.unitypackage │ │ │ ├── ProjectView.unitypackage.meta │ │ │ ├── SQUest.unitypackage │ │ │ ├── SQUest.unitypackage.meta │ │ │ ├── TypeHierarchy.unitypackage │ │ │ ├── TypeHierarchy.unitypackage.meta │ │ │ ├── UGUIEvents.unitypackage │ │ │ └── UGUIEvents.unitypackage.meta │ │ │ ├── README.md │ │ │ ├── README.md.meta │ │ │ ├── RelationsInspector.dll │ │ │ ├── RelationsInspector.dll.meta │ │ │ ├── RelationsInspectorMenuItem.cs │ │ │ ├── RelationsInspectorMenuItem.cs.meta │ │ │ ├── RelationsInspectorResources.meta │ │ │ ├── RelationsInspectorResources │ │ │ ├── ArrowHead.png │ │ │ ├── ArrowHead.png.meta │ │ │ ├── WelcomeWindow.meta │ │ │ ├── WelcomeWindow │ │ │ │ ├── Buy.png │ │ │ │ ├── Buy.png.meta │ │ │ │ ├── Buy_hover.png │ │ │ │ ├── Buy_hover.png.meta │ │ │ │ ├── Discussion.png │ │ │ │ ├── Discussion.png.meta │ │ │ │ ├── Discussion_hover.png │ │ │ │ ├── Discussion_hover.png.meta │ │ │ │ ├── Documentation.png │ │ │ │ ├── Documentation.png.meta │ │ │ │ ├── Documentation_hover.png │ │ │ │ ├── Documentation_hover.png.meta │ │ │ │ ├── Integration.png │ │ │ │ ├── Integration.png.meta │ │ │ │ ├── Integration_hover.png │ │ │ │ ├── Integration_hover.png.meta │ │ │ │ ├── RITitleTextBlack.png │ │ │ │ ├── RITitleTextBlack.png.meta │ │ │ │ ├── RITitleTextWhite.png │ │ │ │ ├── RITitleTextWhite.png.meta │ │ │ │ ├── Twitter.png │ │ │ │ ├── Twitter.png.meta │ │ │ │ ├── Twitter_hover.png │ │ │ │ ├── Twitter_hover.png.meta │ │ │ │ ├── Youtube.png │ │ │ │ ├── Youtube.png.meta │ │ │ │ ├── Youtube_hover.png │ │ │ │ └── Youtube_hover.png.meta │ │ │ ├── disc.png │ │ │ ├── disc.png.meta │ │ │ ├── nextIconDark.png │ │ │ ├── nextIconDark.png.meta │ │ │ ├── nextIconLight.png │ │ │ ├── nextIconLight.png.meta │ │ │ ├── prevIconDark.png │ │ │ ├── prevIconDark.png.meta │ │ │ ├── prevIconLight.png │ │ │ ├── prevIconLight.png.meta │ │ │ ├── settingsIconDark.png │ │ │ ├── settingsIconDark.png.meta │ │ │ ├── settingsIconLight.png │ │ │ └── settingsIconLight.png.meta │ │ │ ├── changelog.md │ │ │ └── changelog.md.meta │ ├── RelationsInspector.meta │ └── RelationsInspector │ │ ├── AutoBackendAttributes.cs │ │ └── AutoBackendAttributes.cs.meta ├── UnityVS.meta └── UnityVS │ ├── Editor.meta │ └── Editor │ ├── SyntaxTree.VisualStudio.Unity.Bridge.dll │ ├── SyntaxTree.VisualStudio.Unity.Bridge.dll.meta │ ├── SyntaxTree.VisualStudio.Unity.Messaging.dll │ ├── SyntaxTree.VisualStudio.Unity.Messaging.dll.meta │ ├── UnityVS.VersionSpecific.dll │ └── UnityVS.VersionSpecific.dll.meta ├── Build ├── AddonTemplate.msbuild ├── Addons.msbuild └── build.bat ├── Docs ├── AssetStore │ ├── ASSET STORE PROVIDER AGREEMENT.txt │ └── screenshots │ │ ├── AssetStoreImages │ │ ├── August2016 │ │ │ ├── PublisherLarge.png │ │ │ ├── PublisherSmall.png │ │ │ ├── Source │ │ │ │ ├── RI-LargeAsset.psd │ │ │ │ ├── RI-LogoComp.ai │ │ │ │ ├── RI-SmallAsset.psd │ │ │ │ ├── bitmap.png │ │ │ │ └── g122.png │ │ │ ├── big.png │ │ │ ├── icon.png │ │ │ └── small.png │ │ ├── Images │ │ │ ├── big.png │ │ │ ├── icon.png │ │ │ ├── publisherLarge.png │ │ │ ├── publisherSmall.png │ │ │ └── small.png │ │ ├── LogoRaw.xcf │ │ ├── LogoSmallNoText.png │ │ ├── LogoWithText.xcf │ │ ├── LogoWithTextSmall.png │ │ ├── LogoWithTextSmall.xcf │ │ ├── LogoWithTextSmallWithBorder.png │ │ ├── LogoWithTextSmallWithBorder.xcf │ │ ├── bigCollapsedLayers.png │ │ ├── bigCollapsedLayers.xcf │ │ ├── bigCollapsedLayers50PercentDiscount.png │ │ ├── bigCollapsedLayers50PercentDiscount.xcf │ │ ├── bigRaw.xcf │ │ ├── description.txt │ │ ├── publisherLarge.xcf │ │ ├── publisherLargeNew.xcf │ │ ├── publisherLogo.png │ │ └── publisherSmall.xcf │ │ ├── AssetStoreTemplates │ │ ├── png │ │ │ ├── big.png │ │ │ ├── icon.png │ │ │ └── small.png │ │ └── psd │ │ │ ├── big.psd │ │ │ ├── icon.psd │ │ │ └── small.psd │ │ ├── RITitleText.png │ │ ├── RITitleText.xcf │ │ ├── RITitleTextWhite.png │ │ ├── collage.png │ │ ├── collage.xcf │ │ ├── new │ │ ├── AINodes.png │ │ ├── AINodes.xcf │ │ ├── AINodesSmall.png │ │ ├── AINodesSmall.xcf │ │ ├── CanvasDependencies.png │ │ ├── CanvasDependencies.xcf │ │ ├── ItemProgression.png │ │ ├── ItemProgression.xcf │ │ ├── PlayMakerCommunicationBackendExample.png │ │ ├── SQuestGraph.png │ │ ├── SceneDependencies.png │ │ ├── SceneDependencies.xcf │ │ ├── SceneMergeRect.png │ │ ├── SceneMergeRect.xcf │ │ ├── SceneMergeSmall.png │ │ ├── SceneMergeSmall.xcf │ │ ├── SpaceImpossible.jpg │ │ ├── SpaceImpossible2.jpg │ │ ├── SpaceImpossibleLabeled.xcf │ │ ├── SpaceImpossibleShot.png │ │ ├── SpaceImpossibleShot.xcf │ │ ├── TypeHierarchy.png │ │ ├── TypeHierarchy.xcf │ │ ├── UFOtags.png │ │ ├── UFOtags.xcf │ │ ├── UIEventBackend.png │ │ └── UIEventBackend.xcf │ │ └── old │ │ ├── GameObjectGraph.jpg │ │ ├── RelationGraphs.gif │ │ ├── SceneHierarchy.gif │ │ ├── SceneHierarchyC.gif │ │ ├── SocialNetwork.gif │ │ ├── SocialNetworkC.gif │ │ ├── TypeHierarchy.gif │ │ ├── TypeHierarchyC.gif │ │ └── feelings.jpg ├── icon.png └── wiki │ ├── Backend Development.md │ ├── Generated │ └── Manual.pdf │ ├── IGraphBackend.md │ ├── Manual.md │ ├── OfflineDoc.md │ ├── RelationsInspectorAPI.md │ └── generatePDF.bat ├── LICENSE ├── MainPackage.msbuild ├── ProjectSettings ├── AudioManager.asset ├── DynamicsManager.asset ├── EditorBuildSettings.asset ├── EditorSettings.asset ├── GraphicsSettings.asset ├── InputManager.asset ├── NavMeshLayers.asset ├── NetworkManager.asset ├── Physics2DSettings.asset ├── ProjectSettings.asset ├── QualitySettings.asset ├── TagManager.asset └── TimeManager.asset ├── README.md ├── RIDLLProject ├── AssemblyInfo.cs ├── Backend │ ├── AcceptTargetsAttribute.cs │ ├── BackendDecoration.cs │ ├── BackendSelectWindow.cs │ ├── BackendUtil.cs │ ├── DescriptionAttribute.cs │ ├── DocumentationAttribute.cs │ ├── HideAttribute.cs │ ├── IGraphBackend.cs │ ├── IGraphBackendInternal.cs │ ├── IconAttribute.cs │ ├── TitleAttribute.cs │ └── VersionAttribute.cs ├── DemoRestriction.cs ├── EdgePlacement │ ├── EdgePlacement.cs │ ├── StraightCirclePlacementProvider.cs │ └── StraightRectPlacementProvider.cs ├── Graph │ ├── FoldUtil.cs │ ├── Graph.cs │ ├── GraphExtensions.cs │ ├── Relation.cs │ └── VertexData.cs ├── Layout │ ├── GraphLayoutAlgorithm.cs │ ├── LayoutParams.cs │ ├── LayoutType.cs │ └── TreeLayoutAlgorithm.cs ├── Log.cs ├── RIStateHistory.cs ├── RelationDrawer │ ├── BasicRelation.cs │ └── RelationDrawUtil.cs ├── RelationsInspectorAPI │ ├── APIv1Implementation.cs │ ├── APIv2Implementation.cs │ ├── IRelationsInspectorAPI.cs │ └── RIInternal.cs ├── RelationsInspectorLib.csproj ├── RelationsInspectorLib.sln ├── RelationsInspectorWindow.cs ├── Serialization │ ├── GraphPosSerialization.cs │ ├── SaveLayoutAttribute.cs │ ├── TopologyStorage.cs │ ├── VertexPosition.cs │ └── VertexPositionStorage.cs ├── Settings │ ├── ProjectSettings.cs │ ├── RelationsInspectorSettings.cs │ ├── Settings.cs │ ├── SettingsInspector.cs │ └── SettingsMenu.cs ├── Style │ ├── EntityWidgetStyle.cs │ ├── MinimapStyle.cs │ ├── RelationDrawerStyle.cs │ ├── Skin.cs │ └── SkinManager.cs ├── Tools │ ├── Extensions │ │ ├── LinqExtensions.cs │ │ ├── RectExtensions.cs │ │ ├── StringExtensions.cs │ │ ├── TypeExtensions.cs │ │ └── Vector2Extensions.cs │ ├── GLMaterials.cs │ ├── GUIUtil.cs │ ├── GraphBuilder.cs │ ├── RNG.cs │ ├── Transform2d.cs │ ├── Tuple.cs │ ├── Tweening │ │ ├── Easing.cs │ │ ├── Tween.cs │ │ ├── TweenCollection.cs │ │ ├── TweenUtil.cs │ │ └── Tweener.cs │ ├── TypeUtil.cs │ └── Util.cs ├── View │ ├── IGraphView.cs │ ├── IMView.cs │ ├── IRelationDrawer.cs │ ├── IViewParent.cs │ ├── Minimap.cs │ └── ViewUtil.cs ├── WelcomeWindow.cs └── WorkSpace │ ├── IWorkspace.cs │ └── Workspace.cs ├── RelationsInspectorRelease.unitypackage ├── Releases ├── 1.1.3 │ ├── RI1.1.3.unitypackage │ └── RIDemo1.1.3.unitypackage ├── 1.1.4 │ ├── RelationsInspectorDemo.unitypackage │ └── RelationsInspectorRelease.unitypackage ├── 1.15 │ ├── RelationsInspectorDemo.unitypackage │ └── RelationsInspectorRelease.unitypackage ├── Demo1.0.5872.22010 │ ├── RelationsInspectorDemo.unitypackage │ └── buildLog1.0.5872.22010.txt ├── Demo1.0.5898.2791 │ ├── RelationsInspectorDemo.unitypackage │ └── buildLog1.0.5898.2780.txt ├── Demo1.1.0.0 │ ├── RelationsInspectorDemo.unitypackage │ └── buildLog1.1.0.0.txt ├── Demo1.1.1 │ ├── RelationsInspectorDemo.unitypackage │ └── buildLog1.1.1.0.txt ├── Demo1.1.2 │ ├── RelationsInspectorDemo.unitypackage │ └── buildLog1.1.2.0.txt ├── Release1.0.5862.27937 │ ├── RelationsInspector.unitypackage │ └── buildLog1.0.5862.27937.txt ├── Release1.0.5898.2780 │ ├── RelationsInspector.unitypackage │ └── buildLog1.0.5898.1900.txt ├── Release1.1.0.0 │ ├── RelationsInspector.unitypackage │ └── buildLog1.1.0.0.txt ├── Release1.1.1 │ ├── RelationsInspector.unitypackage │ └── buildLog1.1.1.0.txt └── Release1.1.2 │ ├── RelationsInspector.unitypackage │ └── buildLog1.1.2.0.txt ├── UnityVS.RelationsInspector.CSharp.Editor.Plugins.csproj ├── UnityVS.RelationsInspector.CSharp.Editor.csproj ├── UnityVS.RelationsInspector.CSharp.Plugins.csproj ├── UnityVS.RelationsInspector.CSharp.csproj ├── UnityVS.RelationsInspector.sln └── build.bat /.gitignore: -------------------------------------------------------------------------------- 1 | /Temp/ 2 | /Library/ 3 | /obj/ 4 | /TestProjects/ 5 | /BuildLogs/ 6 | /.vs/ 7 | 8 | /startUnity.bat 9 | /RelationsInspector.unitypackage 10 | /RelationsInspectorDemo.unitypackage 11 | /RelationsInspectorDebug.unitypackage 12 | /UnityVS.RelationsInspector.v11.suo 13 | /UnityVS.RelationsInspector.v12.suo 14 | 15 | /RIDLLProject/.vs/ 16 | /RIDLLProject/bin/ 17 | /RIDLLProject/obj/ 18 | /RIDLLProject/RelationsInspectorLib.csproj.user 19 | /RIDLLProject/RelationsInspectorLib.v11.suo 20 | 21 | /Assets/ScriptableObjectSpawner* 22 | /Assets/UnityTestTools* 23 | /Assets/RelationsInspector/Editor/LayoutCaches/ 24 | /Assets/RelationsInspector/Editor/RelationsInspector.dll* 25 | /Assets/RelationsInspector/Editor/RelationsInspector.pdb* 26 | /Assets/RelationsInspector/Editor/RelationsInspectorResources/DefaultSkin.asset* 27 | /Assets/RelationsInspector/Editor/RelationsInspectorResources/RIWindowLightSkin.asset 28 | /Assets/RelationsInspector/Editor/RelationsInspectorResources/RIWindowLightSkin.asset.meta 29 | /Assets/RelationsInspector/Editor/RelationsInspectorResources/RIWindowDarkSkin.asset 30 | /Assets/RelationsInspector/Editor/RelationsInspectorResources/RIWindowDarkSkin.asset.meta 31 | /Assets/RelationsInspector/Editor/RelationsInspectorResources/DefaultConfig.asset* 32 | /Assets/RelationsInspector/Editor/RelationsInspectorResources/Settings.asset 33 | /Assets/RelationsInspector/Editor/SourceRI.zip* 34 | /Assets/RelationsInspector/Editor/SourceCodeRI.zip 35 | /Assets/RelationsInspector/Editor/SourceCodeRI.zip.meta 36 | 37 | /Docs/layoutSavingTodo.txt 38 | /Docs/screenshots/ 39 | /Docs/PromoVideo/ 40 | 41 | /Docs/DoNotTrack/ 42 | Assets/Plugins/Editor/RelationsInspector/BackendUtils/ 43 | Assets/Plugins/Editor/RelationsInspector/SourceCodeRI.zip 44 | Assets/Plugins/Editor/RelationsInspector/SourceCodeRI.zip.meta 45 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/.gitmodules -------------------------------------------------------------------------------- /Assets/Plugins.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 49833d9c3564b604bbaa5f8fd6a9bde7 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 627a443d5d26914409d119d5f70b541e 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8244d617ba50ea844af6609f3a38036c 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/BackendUtils.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8612c63d31a2f7341babb727940d7b0f 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: bfa4e10cdd6b3de45baa38f8fa3dfcf2 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/AutoBackend.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2f2d410912a8b9d4e87f818349b880bf 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/AutoBackend/RIAutoBackend.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Linq; 3 | using System.Reflection; 4 | using UnityEngine; 5 | 6 | namespace RelationsInspector.Backend.AutoBackend 7 | { 8 | public class RIAutoBackend : MinimalBackend where T : class 9 | { 10 | IEnumerable relatedFields; 11 | IEnumerable relatingFields; 12 | 13 | public override void Awake( GetAPI getAPI ) 14 | { 15 | relatingFields = ReflectionUtil.GetAttributeFields(); 16 | relatedFields = ReflectionUtil.GetAttributeFields(); 17 | if ( !relatingFields.Any() && !relatedFields.Any() ) 18 | Debug.LogError( "Type has auto backend attribute, but no fields marked as related or relating: " + typeof( T ) ); 19 | base.Awake( getAPI ); 20 | } 21 | 22 | public override IEnumerable> GetRelations( T entity ) 23 | { 24 | var outRelations = relatedFields 25 | .SelectMany( fInfo => ReflectionUtil.GetValues( fInfo, entity ) ) 26 | .Select( other => new Relation( entity, other, string.Empty ) ); 27 | 28 | var inRelations = relatingFields 29 | .SelectMany( fInfo => ReflectionUtil.GetValues( fInfo, entity ) ) 30 | .Select( other => new Relation( other, entity, string.Empty ) ); 31 | 32 | return outRelations.Concat( inRelations ); 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/AutoBackend/RIAutoBackend.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2ade0bc5b99df3b4aba4a8d7977ee626 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/AutoBackend/ReflectionUtil.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Reflection; 5 | 6 | namespace RelationsInspector.Backend.AutoBackend 7 | { 8 | public class ReflectionUtil 9 | { 10 | public static IEnumerable GetAttributeFields() 11 | { 12 | return typeof( P ) 13 | .GetFields( BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance ) 14 | .Where( fInfo => HasAttribute( fInfo, typeof( S ) ) ); 15 | } 16 | 17 | static bool HasAttribute( MemberInfo mInfo, Type attrType ) 18 | { 19 | return mInfo.GetCustomAttributes( attrType, false ).Any(); 20 | } 21 | 22 | public static IEnumerable GetValues( FieldInfo fInfo, T fObj ) where T : class 23 | { 24 | // how to get T objects out of different field types 25 | var extractValues = new Dictionary>>() 26 | { 27 | {typeof(T), obj => new T[] { obj as T } }, 28 | {typeof(List), obj => ( obj as List ) ?? Enumerable.Empty() }, 29 | {typeof(T[]), obj => ( obj as T[] ) ?? Enumerable.Empty() } 30 | }; 31 | 32 | if ( !extractValues.ContainsKey( fInfo.FieldType ) ) 33 | return Enumerable.Empty(); 34 | 35 | return extractValues[ fInfo.FieldType ] 36 | .Invoke( fInfo.GetValue( fObj ) ) 37 | .Where( v => v != null ); 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/AutoBackend/ReflectionUtil.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 928f7180f0c38824da8a187f6b78210f 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/HierarchyExample.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3dfe0d12818a17f4a9e80ec8a02aefa3 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/HierarchyExample/SceneHierarchyBackend.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 53a0d54d9fd93dd478ef471886581f41 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/HierarchyExample/TagBackend.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using UnityEditor; 5 | using System.Linq; 6 | 7 | namespace RelationsInspector.Backend.Scene 8 | { 9 | public class Tag 10 | { 11 | public string value; 12 | } 13 | 14 | [Title("GameObject tags")] 15 | [Version("1.0.0")] 16 | [Description("Shows all tags used in the scene," + "and the GameObjects that use them.")] 17 | public class TagBackend : MinimalBackend 18 | { 19 | List tagObjects = new List(); 20 | string searchstring; 21 | 22 | public override IEnumerable Init( object target ) 23 | { 24 | var asGo = target as GameObject; 25 | if ( asGo == null ) 26 | yield break; 27 | 28 | yield return asGo; 29 | yield return GetTagObj( asGo.tag ); 30 | } 31 | 32 | public override IEnumerable> GetRelations( object entity ) 33 | { 34 | var asGO = entity as GameObject; 35 | if ( asGO != null ) 36 | yield return new Relation( GetTagObj( asGO.tag ), asGO, string.Empty ); 37 | } 38 | 39 | Tag GetTagObj( string tag ) 40 | { 41 | string tagTitle = "Tag: " + tag; 42 | 43 | var obj = tagObjects.FirstOrDefault( o => o.value == tagTitle ); 44 | if ( obj == null ) 45 | { 46 | obj = new Tag() { value = tagTitle };//Object.Instantiate( EditorGUIUtility.whiteTexture ); 47 | tagObjects.Add( obj ); 48 | } 49 | return obj; 50 | } 51 | 52 | bool ContainsUntaggedTargets() 53 | { 54 | // if there are, there must be a tag object for them 55 | return tagObjects != null && tagObjects.Any( o => o.value == "Tag: Untagged" ); 56 | } 57 | 58 | bool IsUntagged( object obj ) 59 | { 60 | var asGameObject = obj as GameObject; 61 | return asGameObject != null && asGameObject.tag != "Untagged"; 62 | } 63 | 64 | public override Rect OnGUI() 65 | { 66 | GUILayout.BeginHorizontal( EditorStyles.toolbar ); 67 | { 68 | // option: use all gameobjects of the active scene as targets 69 | if ( GUILayout.Button( "Show active scene", EditorStyles.toolbarButton ) ) 70 | api.ResetTargets( Object.FindObjectsOfType().Cast().ToArray() ); 71 | 72 | // option: remove untagged objects 73 | if ( ContainsUntaggedTargets() && 74 | GUILayout.Button( "Hide untagged", EditorStyles.toolbarButton ) ) 75 | api.ResetTargets( api.GetTargets().Where( IsUntagged ).ToArray() ); 76 | 77 | GUILayout.FlexibleSpace(); 78 | 79 | searchstring = BackendUtil.DrawEntitySelectSearchField( searchstring, api ); 80 | } 81 | GUILayout.EndHorizontal(); 82 | return base.OnGUI(); 83 | } 84 | 85 | public override GUIContent GetContent( object entity ) 86 | { 87 | var asGo = entity as GameObject; 88 | if ( asGo != null ) 89 | return new GUIContent( asGo.name, null, asGo.name ); 90 | 91 | var asTag = entity as Tag; 92 | if ( asTag != null ) 93 | return new GUIContent( asTag.value, null, asTag.value ); 94 | 95 | return new GUIContent( "unknown object " + entity.ToString(), null, string.Empty ); 96 | } 97 | 98 | public override void OnEntitySelectionChange( object[] selection ) 99 | { 100 | base.OnEntitySelectionChange( selection.OfType().ToArray() ); 101 | } 102 | } 103 | } 104 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Backends/HierarchyExample/TagBackend.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e8c766ad7dc9f51469eefc0a3e3f0e26 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Manual.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Manual.pdf -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Manual.pdf.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 332687af97759734cb57455ad504ff4c 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ac13811c318dc0541b672a908da1b4ae 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/AssetReferences.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/AssetReferences.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/AssetReferences.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c953078b4f71dc0418431c02fdec7cb3 3 | timeCreated: 1457940221 4 | licenseType: Free 5 | DefaultImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/DialogueSystem.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/DialogueSystem.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/DialogueSystem.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 488f203b5a5701d45b0a5233a0f36e10 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/InventoryMaster.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/InventoryMaster.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/InventoryMaster.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b5ea4fbd70d637342ad8952a767366d0 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/InventoryPro.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/InventoryPro.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/InventoryPro.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2498e2d18cefc644e9b11a38145d239e 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/PlayMakerFSMCommunication.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/PlayMakerFSMCommunication.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/PlayMakerFSMCommunication.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 789d47358dbe8c2429f3f07d08391213 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/ProjectView.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/ProjectView.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/ProjectView.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0106cc8fae4f2f7498ab782ab5f689d3 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/SQUest.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/SQUest.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/SQUest.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2658aa53266a01748a3455b938833ab8 3 | timeCreated: 1457940018 4 | licenseType: Free 5 | DefaultImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/TypeHierarchy.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/TypeHierarchy.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/TypeHierarchy.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: eba556e74de209244859d72087b56501 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/UGUIEvents.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/Packages/UGUIEvents.unitypackage -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/Packages/UGUIEvents.unitypackage.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b70f5aa0f8c123e4fb89c16b2a785c56 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/README.md: -------------------------------------------------------------------------------- 1 | ## Relations inspector 2 | 3 | This is a Unity editor tool for displaying and modifying relations between any kind of project data. You can access it through the Window menu. For more information, refer to the [manual](https://github.com/seldomU/RIBackendUtil/wiki/RelationsInspector-Manual). 4 | 5 | ### Credits 6 | * ArrowHead icon by Nemo (public domain): http://pixabay.com/en/arrow-left-point-pointer-sharp-40169/ 7 | * Gears icon by sempron (public domain): https://pixabay.com/en/gear-icon-innovation-industry-856921/ 8 | * Welcome window icons by aiconia.net (CC0 1.0 public domain) -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/README.md.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 12ee8e4d7bf994f4d9a04c7274ad4eb0 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspector.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspector.dll -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspector.dll.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: eb4eaaabc8cc3594aa76719228fcd76f 3 | MonoAssemblyImporter: 4 | serializedVersion: 1 5 | iconMap: {} 6 | executionOrder: {} 7 | userData: 8 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorMenuItem.cs: -------------------------------------------------------------------------------- 1 | using UnityEditor; 2 | using RelationsInspector; 3 | 4 | public class RelationsInspectorMenuItem 5 | { 6 | [MenuItem("Window/RelationsInspector")] 7 | static void SpawnWindow() 8 | { 9 | EditorWindow.GetWindow("Relations", typeof(SceneView)); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorMenuItem.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 840706ff65f6c584688e48963802a8c7 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b7fc7e5cb89a3a145a32817a206132fb 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/ArrowHead.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/ArrowHead.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/ArrowHead.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3861beedaaa8b5443aab88a1b54316ff 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | seamlessCubemap: 0 24 | textureFormat: -1 25 | maxTextureSize: 1024 26 | textureSettings: 27 | filterMode: -1 28 | aniso: -1 29 | mipBias: -1 30 | wrapMode: -1 31 | nPOTScale: 1 32 | lightmap: 0 33 | compressionQuality: 50 34 | spriteMode: 0 35 | spriteExtrude: 1 36 | spriteMeshType: 1 37 | alignment: 0 38 | spritePivot: {x: .5, y: .5} 39 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 40 | spritePixelsToUnits: 100 41 | alphaIsTransparency: 0 42 | textureType: -1 43 | buildTargetSettings: [] 44 | spriteSheet: 45 | sprites: [] 46 | spritePackingTag: 47 | userData: 48 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8794c146be478ac4b884981db9148d53 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Buy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Buy.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Buy.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 225c7e5dd75d67d48a51b0c0fce774c5 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Buy_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Buy_hover.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Buy_hover.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 388409a88fa1a5d40922568b55a22add 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Discussion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Discussion.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Discussion.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2487b019fd3d5ff498d51e2b14d66b8e 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Discussion_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Discussion_hover.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Discussion_hover.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: cc4d6297f288d26479132f498e658b5a 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Documentation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Documentation.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Documentation.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4976d0906f36e404f97f1205db404201 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Documentation_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Documentation_hover.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Documentation_hover.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 07a9994686e8e6642ba9dc16ec1845f6 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Integration.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Integration.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Integration.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6b2eb5d858f32214d8a08db5f7618d28 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Integration_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Integration_hover.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Integration_hover.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 270b52fb8ccbe7841a34fc0e39b1635d 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/RITitleTextBlack.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/RITitleTextBlack.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/RITitleTextBlack.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4ec05a3646e4bc04cb6e298f0a0bcf56 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/RITitleTextWhite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/RITitleTextWhite.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/RITitleTextWhite.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1e7c942f080729d4ba407ca4f4d1b81d 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Twitter.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Twitter.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f4faedc6b0e22704ab74fd4c3070827d 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Twitter_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Twitter_hover.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Twitter_hover.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fc1dc58cfa79fcc44a2f97d1d027a494 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Youtube.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Youtube.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Youtube.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c5a34ffe55f5ef14ba2fc0616def37da 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Youtube_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Youtube_hover.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/WelcomeWindow/Youtube_hover.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 064b3c49f9b58b04387ab954b6f95b3a 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/disc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/disc.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/disc.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 29882f4a65663dc499a9c1f2fbbb90c3 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/nextIconDark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/nextIconDark.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/nextIconDark.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: cb7608a1b0eb09a4da2042aa53ed039d 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | seamlessCubemap: 0 24 | textureFormat: -1 25 | maxTextureSize: 1024 26 | textureSettings: 27 | filterMode: -1 28 | aniso: -1 29 | mipBias: -1 30 | wrapMode: -1 31 | nPOTScale: 1 32 | lightmap: 0 33 | compressionQuality: 50 34 | spriteMode: 0 35 | spriteExtrude: 1 36 | spriteMeshType: 1 37 | alignment: 0 38 | spritePivot: {x: .5, y: .5} 39 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 40 | spritePixelsToUnits: 100 41 | alphaIsTransparency: 0 42 | textureType: -1 43 | buildTargetSettings: [] 44 | spriteSheet: 45 | sprites: [] 46 | spritePackingTag: 47 | userData: 48 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/nextIconLight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/nextIconLight.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/nextIconLight.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b8b0785860d46f144873f37f01b57d60 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | seamlessCubemap: 0 24 | textureFormat: -1 25 | maxTextureSize: 1024 26 | textureSettings: 27 | filterMode: -1 28 | aniso: -1 29 | mipBias: -1 30 | wrapMode: -1 31 | nPOTScale: 1 32 | lightmap: 0 33 | compressionQuality: 50 34 | spriteMode: 0 35 | spriteExtrude: 1 36 | spriteMeshType: 1 37 | alignment: 0 38 | spritePivot: {x: .5, y: .5} 39 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 40 | spritePixelsToUnits: 100 41 | alphaIsTransparency: 0 42 | textureType: -1 43 | buildTargetSettings: [] 44 | spriteSheet: 45 | sprites: [] 46 | spritePackingTag: 47 | userData: 48 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/prevIconDark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/prevIconDark.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/prevIconDark.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ad5f6b542dfb01f48871fbaef68588d0 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | seamlessCubemap: 0 24 | textureFormat: -1 25 | maxTextureSize: 1024 26 | textureSettings: 27 | filterMode: -1 28 | aniso: -1 29 | mipBias: -1 30 | wrapMode: -1 31 | nPOTScale: 1 32 | lightmap: 0 33 | compressionQuality: 50 34 | spriteMode: 0 35 | spriteExtrude: 1 36 | spriteMeshType: 1 37 | alignment: 0 38 | spritePivot: {x: .5, y: .5} 39 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 40 | spritePixelsToUnits: 100 41 | alphaIsTransparency: 0 42 | textureType: -1 43 | buildTargetSettings: [] 44 | spriteSheet: 45 | sprites: [] 46 | spritePackingTag: 47 | userData: 48 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/prevIconLight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/prevIconLight.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/prevIconLight.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7c9c243eaa13b4d48aee5e00c6344c8c 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | seamlessCubemap: 0 24 | textureFormat: -1 25 | maxTextureSize: 1024 26 | textureSettings: 27 | filterMode: -1 28 | aniso: -1 29 | mipBias: -1 30 | wrapMode: -1 31 | nPOTScale: 1 32 | lightmap: 0 33 | compressionQuality: 50 34 | spriteMode: 0 35 | spriteExtrude: 1 36 | spriteMeshType: 1 37 | alignment: 0 38 | spritePivot: {x: .5, y: .5} 39 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 40 | spritePixelsToUnits: 100 41 | alphaIsTransparency: 0 42 | textureType: -1 43 | buildTargetSettings: [] 44 | spriteSheet: 45 | sprites: [] 46 | spritePackingTag: 47 | userData: 48 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/settingsIconDark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/settingsIconDark.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/settingsIconDark.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a7eb1b01754d2624881e59555a6b556c 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | seamlessCubemap: 0 24 | textureFormat: -1 25 | maxTextureSize: 1024 26 | textureSettings: 27 | filterMode: -1 28 | aniso: -1 29 | mipBias: -1 30 | wrapMode: -1 31 | nPOTScale: 1 32 | lightmap: 0 33 | compressionQuality: 50 34 | spriteMode: 0 35 | spriteExtrude: 1 36 | spriteMeshType: 1 37 | alignment: 0 38 | spritePivot: {x: .5, y: .5} 39 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 40 | spritePixelsToUnits: 100 41 | alphaIsTransparency: 0 42 | textureType: -1 43 | buildTargetSettings: [] 44 | spriteSheet: 45 | sprites: [] 46 | spritePackingTag: 47 | userData: 48 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/settingsIconLight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/settingsIconLight.png -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/RelationsInspectorResources/settingsIconLight.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f5a08c65ef8f8cd499d537049ee1d885 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | seamlessCubemap: 0 24 | textureFormat: -1 25 | maxTextureSize: 1024 26 | textureSettings: 27 | filterMode: -1 28 | aniso: -1 29 | mipBias: -1 30 | wrapMode: -1 31 | nPOTScale: 1 32 | lightmap: 0 33 | compressionQuality: 50 34 | spriteMode: 0 35 | spriteExtrude: 1 36 | spriteMeshType: 1 37 | alignment: 0 38 | spritePivot: {x: .5, y: .5} 39 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 40 | spritePixelsToUnits: 100 41 | alphaIsTransparency: 0 42 | textureType: -1 43 | buildTargetSettings: [] 44 | spriteSheet: 45 | sprites: [] 46 | spritePackingTag: 47 | userData: 48 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/changelog.md: -------------------------------------------------------------------------------- 1 | ### Version 1.1.5 2 | * Date 2017.09.02 3 | * Revision cc835a1 4 | * Changes 5 | * fixed EditorPrefs error in Welcome window for Unity 2017.1 6 | 7 | ### Version 1.1.4 8 | * Date 2017.03.11 9 | * Revision ccae6f9 10 | * Changes 11 | * updated S-Quest backend to reflect S-Quest changes 12 | 13 | ### Version 1.1.3 14 | * Date 2016.12.27 15 | * Revision 8eee8081 16 | * Changes 17 | * fixed Asset-reference package compile error in Unity 5.4 and up 18 | * fixed uGUI event backend error due engine-internal changes 19 | 20 | ### Version 1.1.2 21 | * Date 2016.05.10 22 | * Revision 45fa9fc 23 | * Changes 24 | * added backend for PlayMaker inter-FSM communication 25 | * added backends for Dialogue System 26 | * project view backend can now prune the tree and highlight nodes based on asset types and scene-dependency 27 | * added backend attributes: Title, Version, Description, Documentation, Icon and Hide 28 | * backend selection dropdown makes use of the attributes above 29 | 30 | ### Version 1.1.1 31 | * Date 2016.03.30 32 | * Revision 3823222 33 | * Changes 34 | * graph layout: increase gravity. disjunct subgraphs will now be closer together 35 | * tree detection: fixed false positive when there are disjunct subtrees 36 | * added graph backend packages 37 | * InventoryMaster 38 | * S-Quest 39 | * Asset references and dependency 40 | * uGUI events 41 | * project view 42 | * type hierarchy 43 | * added Welcome window, where addons can be managed 44 | 45 | ### Version 1.1.0 46 | * Date 2016.03.10 47 | * Revision b58da13 48 | * Changes 49 | * moved base directory from RelationsInspector to Plugins/RelationsInspector 50 | * add API methods GetEntities and GetRelations 51 | * tooltip placement now takes window borders into consideration 52 | * minor improvements to example backends 53 | 54 | ### Version 1.0.5897.2780 55 | * Date 2016.02.24 56 | * Revision 02c0305 57 | * Changes 58 | * ResetTargets now also accepts a backend type along with the targets 59 | * added GetAPI1 property to API 60 | 61 | ### Version 1.0.5862.27937 62 | * Date 2016.01.19 63 | * Revision 760780a 64 | -------------------------------------------------------------------------------- /Assets/Plugins/Editor/RelationsInspector/changelog.md.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 84b735f66378f4947aed85260326588f 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Plugins/RelationsInspector.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7f69f946b6c75174093981443cce4dd9 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Plugins/RelationsInspector/AutoBackendAttributes.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector.Backend.AutoBackend 4 | { 5 | // indicates that RI should make an RIAutoBackend type for the marked type 6 | [AttributeUsage( AttributeTargets.Class )] 7 | public class AutoBackendAttribute : Attribute { } 8 | 9 | // indicates that there's a relation from the object to each of the field's objects 10 | [AttributeUsage( AttributeTargets.Field | AttributeTargets.Property )] 11 | public class RelatedAttribute : Attribute { } 12 | 13 | // indicates that there's a relation from each of the field's objects to the object 14 | [AttributeUsage( AttributeTargets.Field | AttributeTargets.Property )] 15 | public class RelatingAttribute : Attribute { } 16 | } 17 | -------------------------------------------------------------------------------- /Assets/Plugins/RelationsInspector/AutoBackendAttributes.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 508186bc9effaad43b8c286a04adadfb 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/UnityVS.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d88abc9f091edb94793fcb9cc9fad968 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/UnityVS/Editor.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6e71a3e2fb5854e43823a9da25b68e21 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/UnityVS/Editor/SyntaxTree.VisualStudio.Unity.Bridge.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/UnityVS/Editor/SyntaxTree.VisualStudio.Unity.Bridge.dll -------------------------------------------------------------------------------- /Assets/UnityVS/Editor/SyntaxTree.VisualStudio.Unity.Bridge.dll.meta: -------------------------------------------------------------------------------- 1 | guid: 38d405c119fcc7c4e83d4a478a40ff2f 2 | -------------------------------------------------------------------------------- /Assets/UnityVS/Editor/SyntaxTree.VisualStudio.Unity.Messaging.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/UnityVS/Editor/SyntaxTree.VisualStudio.Unity.Messaging.dll -------------------------------------------------------------------------------- /Assets/UnityVS/Editor/SyntaxTree.VisualStudio.Unity.Messaging.dll.meta: -------------------------------------------------------------------------------- 1 | guid: 4ad02dc83da735c4e8d945332b9202f6 2 | -------------------------------------------------------------------------------- /Assets/UnityVS/Editor/UnityVS.VersionSpecific.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Assets/UnityVS/Editor/UnityVS.VersionSpecific.dll -------------------------------------------------------------------------------- /Assets/UnityVS/Editor/UnityVS.VersionSpecific.dll.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f157a8121a292f146b7507de9b6762e9 3 | MonoAssemblyImporter: 4 | serializedVersion: 1 5 | iconMap: {} 6 | executionOrder: {} 7 | userData: 8 | -------------------------------------------------------------------------------- /Build/AddonTemplate.msbuild: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | "C:\Program Files (x86)\Unity4.3.0\Editor\Unity.exe" 5 | 6 | a 7 | b 8 | c 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /Build/build.bat: -------------------------------------------------------------------------------- 1 | "C:\Program Files (x86)\MSBuild\14.0\Bin\msbuild.exe" Addons.msbuild /t:%1 -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/PublisherLarge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/PublisherLarge.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/PublisherSmall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/PublisherSmall.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/RI-LargeAsset.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/RI-LargeAsset.psd -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/RI-LogoComp.ai: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/RI-LogoComp.ai -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/RI-SmallAsset.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/RI-SmallAsset.psd -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/bitmap.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/bitmap.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/g122.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/Source/g122.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/big.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/big.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/icon.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/August2016/small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/August2016/small.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/Images/big.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/Images/big.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/Images/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/Images/icon.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/Images/publisherLarge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/Images/publisherLarge.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/Images/publisherSmall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/Images/publisherSmall.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/Images/small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/Images/small.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/LogoRaw.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/LogoRaw.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/LogoSmallNoText.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/LogoSmallNoText.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/LogoWithText.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/LogoWithText.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmall.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmall.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmall.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmallWithBorder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmallWithBorder.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmallWithBorder.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/LogoWithTextSmallWithBorder.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers50PercentDiscount.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers50PercentDiscount.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers50PercentDiscount.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/bigCollapsedLayers50PercentDiscount.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/bigRaw.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/bigRaw.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/description.txt: -------------------------------------------------------------------------------- 1 | Font: Sitka Small Bold -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/publisherLarge.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/publisherLarge.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/publisherLargeNew.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/publisherLargeNew.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/publisherLogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/publisherLogo.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreImages/publisherSmall.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreImages/publisherSmall.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreTemplates/png/big.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreTemplates/png/big.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreTemplates/png/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreTemplates/png/icon.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreTemplates/png/small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreTemplates/png/small.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreTemplates/psd/big.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreTemplates/psd/big.psd -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreTemplates/psd/icon.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreTemplates/psd/icon.psd -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/AssetStoreTemplates/psd/small.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/AssetStoreTemplates/psd/small.psd -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/RITitleText.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/RITitleText.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/RITitleText.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/RITitleText.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/RITitleTextWhite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/RITitleTextWhite.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/collage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/collage.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/collage.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/collage.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/AINodes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/AINodes.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/AINodes.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/AINodes.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/AINodesSmall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/AINodesSmall.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/AINodesSmall.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/AINodesSmall.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/CanvasDependencies.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/CanvasDependencies.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/CanvasDependencies.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/CanvasDependencies.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/ItemProgression.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/ItemProgression.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/ItemProgression.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/ItemProgression.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/PlayMakerCommunicationBackendExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/PlayMakerCommunicationBackendExample.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SQuestGraph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SQuestGraph.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SceneDependencies.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SceneDependencies.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SceneDependencies.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SceneDependencies.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SceneMergeRect.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SceneMergeRect.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SceneMergeRect.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SceneMergeRect.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SceneMergeSmall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SceneMergeSmall.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SceneMergeSmall.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SceneMergeSmall.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SpaceImpossible.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SpaceImpossible.jpg -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SpaceImpossible2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SpaceImpossible2.jpg -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SpaceImpossibleLabeled.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SpaceImpossibleLabeled.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SpaceImpossibleShot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SpaceImpossibleShot.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/SpaceImpossibleShot.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/SpaceImpossibleShot.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/TypeHierarchy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/TypeHierarchy.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/TypeHierarchy.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/TypeHierarchy.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/UFOtags.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/UFOtags.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/UFOtags.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/UFOtags.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/UIEventBackend.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/UIEventBackend.png -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/new/UIEventBackend.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/new/UIEventBackend.xcf -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/GameObjectGraph.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/GameObjectGraph.jpg -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/RelationGraphs.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/RelationGraphs.gif -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/SceneHierarchy.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/SceneHierarchy.gif -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/SceneHierarchyC.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/SceneHierarchyC.gif -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/SocialNetwork.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/SocialNetwork.gif -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/SocialNetworkC.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/SocialNetworkC.gif -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/TypeHierarchy.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/TypeHierarchy.gif -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/TypeHierarchyC.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/TypeHierarchyC.gif -------------------------------------------------------------------------------- /Docs/AssetStore/screenshots/old/feelings.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/AssetStore/screenshots/old/feelings.jpg -------------------------------------------------------------------------------- /Docs/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/icon.png -------------------------------------------------------------------------------- /Docs/wiki/Generated/Manual.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Docs/wiki/Generated/Manual.pdf -------------------------------------------------------------------------------- /Docs/wiki/IGraphBackend.md: -------------------------------------------------------------------------------- 1 | IGraphBackend members 2 | ------------- 3 | 4 | Backend interface. The two generic parameters are the graph entity type T and relation type P. 5 | 6 | ``` csharp 7 | IEnumerable Init(IEnumerable targets, RelationsInspectorAPI api); 8 | ``` 9 | > First call the backend gets. Returned entities are used as roots of graph contstruction. API parameter is for any graph manipulation the backend may want to make, like adding/removing entities or relations. 10 | 11 | ``` csharp 12 | IEnumerable> GetRelations(T entity); 13 | ``` 14 | > Graph construction needs the tags and targets of all relations in which the entity is the subject. 15 | 16 | #### Graph modification 17 | 18 | ``` csharp 19 | void CreateEntity(Vector2 position); 20 | ``` 21 | > UI wants to create a new entity at the given graph position. 22 | 23 | ``` csharp 24 | void CreateRelation(T source, T target, P tag); 25 | ``` 26 | > UI wants to create a new relation with the given properties. 27 | 28 | #### Content drawing 29 | 30 | ``` csharp 31 | Rect DrawContent(T entity, EntityDrawContext drawContext); 32 | ``` 33 | > UI needs a rect, visually representing the given entity. 34 | 35 | ``` csharp 36 | Color GetRelationColor(P relationTagValue); 37 | ``` 38 | > UI needs the color in which to paint the relation marker. 39 | 40 | ``` csharp 41 | string GetTooltip(T entity); 42 | ``` 43 | > UI needs a string to use as entity widget tooltip. 44 | 45 | ``` csharp 46 | Rect OnGUI(); 47 | ``` 48 | > UI is being drawn. Backend gets a chance to draw its own controls. Returns the remaining space as rect. The graph is then drawn in that rect. 49 | 50 | #### Other events 51 | 52 | ``` csharp 53 | void OnEntityContextClick(IEnumerable entities); 54 | ``` 55 | > UI got a context click on the given entities. Backend may want to show a menu. 56 | 57 | ``` csharp 58 | void OnEntitySelectionChange(T[] selection); 59 | ``` 60 | > UI selection changed. 61 | 62 | ``` csharp 63 | void OnRelationContextClick(T source, T target, P tag); 64 | ``` 65 | > UI got a context click on the given relation's marker. Backend may wnat to show a menu. -------------------------------------------------------------------------------- /Docs/wiki/Manual.md: -------------------------------------------------------------------------------- 1 | Relations inspector manual 2 | ========================== 3 | 4 | The relations inspector is a Unity editor extension that lets the user visualize and edit relations between all kinds of project data. It will be called *RI* in this manual, to avoid confusion with Unity's inspector window. 5 | 6 | ![screenshots](http://i.imgur.com/1OgxgAF.gif "some screenshots") 7 | 8 | Each kind of relation graph is driven by a backend class. A backend defines what relations to show for a specific object type. 9 | 10 | Using the RI 11 | ------------------- 12 | Typically, you drag and drop some assets (the target objects) into the RI window. The RI will pick a backend that fits their types and show a graph made by the backend from your target objects. The auto-selected backend may not be the one you want, so the graph might look underwhelming. In the toolbar you'll find a dropdown where you can choose between all backends that fit your target types. 13 | 14 | The toolbar also contains: 15 | 16 | * a **Clear** button, that will reset the target objects and the graph 17 | * a **Refresh** button, that will generate a new graph from the current target objects 18 | * a **Layout** selector, that lets you arrange the graph in a tree layout, if applicable 19 | * a **Entity widget** selector, that offers two ways of displaying entity nodes 20 | 21 | The rest of the window contains the graph and its minimap, as well as backend-specific GUI controls, if there are any. The graph area responds to the following inputs: 22 | 23 | * dragging objects into the window makes them the new inspection targets. If *control* is held down at the same time, the objects are added to the existing inspection targets. 24 | * moving the mouse wheel zooms in and out 25 | * dragging the graph-area while the right mouse button is pressed, shifts the graph 26 | * clicking into the minimap makes the window focus on the clicked location 27 | * left-clicking an entity widget will select it. Pressing control at the same time adds the entity to the existing selection. 28 | * dragging the graph-area while the left mouse button is pressed, selects all entities in the drag area 29 | * right-clicking the graph-area while pressing control creates an entity, if the backend permits 30 | * right clicking on entity- and relationwidgets is handled by each backend. It may open a context menu 31 | 32 | 33 | If you want to create a graph from scratch: clear the window, select your backend and use its controls to create and modify your data. 34 | -------------------------------------------------------------------------------- /Docs/wiki/RelationsInspectorAPI.md: -------------------------------------------------------------------------------- 1 | RelationsInspectorAPI 2 | --------------------- 3 | 4 | ``` csharp 5 | void ResetTargets(object[] targets); 6 | ``` 7 | > Clears the current graph and creates a new one for the given targets. 8 | 9 | ``` csharp 10 | void AddTargets(object[] targets); 11 | ``` 12 | > Clears the current graph and creates a new one for the union of existing and added targets. 13 | 14 | ``` csharp 15 | void SetBackend(Type backendType); 16 | ``` 17 | > Enforces selection of the given backend type. 18 | 19 | ``` csharp 20 | void Repaint(); 21 | ``` 22 | > Draws a fresh view of the graph. 23 | 24 | #### Graph manipulation 25 | ``` csharp 26 | void AddEntity(object entity, Vector2 position); 27 | ``` 28 | > Adds the entity to the graph. The position is in graph coordinates, not window coordinates. If unsure, pass Vector2.zero. 29 | 30 | ``` csharp 31 | void RemoveEntity(object entity); 32 | ``` 33 | > Removes entity and all its relations from the graph. 34 | 35 | ``` csharp 36 | void AddRelation(object sourceEntity, object targetEntity, object tag); 37 | ``` 38 | > Adds relation between the given entities to the graph. 39 | 40 | ``` csharp 41 | void RemoveRelation(object sourceEntity, object targetEntity, object tag); 42 | ``` 43 | > Removes the specified relation from the graph. If multiple matching relations exist, only the first one found will be removed. 44 | 45 | ``` csharp 46 | void InitRelation(object[] sourceEntity, object tag); 47 | ``` 48 | > Makes the UI initiate the creation of a new relation. The user then gets to pick the target entity, which will result in call to the backend's `CreateEntity`. -------------------------------------------------------------------------------- /Docs/wiki/generatePDF.bat: -------------------------------------------------------------------------------- 1 | pandoc -s -o Generated/Manual.pdf OfflineDoc.md --toc -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2016-2020 seldomU 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /MainPackage.msbuild: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Release 5 | Demo 6 | $(MSBuildThisFileDirectory) 7 | $(RIProjPath)RIDLLProject\ 8 | $(RIAssetBasePath)RelationsInspector.dll 9 | $(DllSourcePath)RelationsInspectorLib.csproj 10 | $(RIProjPath)Assets\Plugins\Editor\RelationsInspector\ 11 | $(RIAssetBasePath)RelationsInspectorResources\ 12 | $(RIAssetResourcesPath)RIWindowLightSkin.asset 13 | $(RIAssetResourcesPath)RIWindowDarkSkin.asset 14 | $(RIAssetResourcesPath)Settings.asset 15 | $(RIAssetBasePath)SourceCodeRI.zip 16 | $(RIAssetBasePath)LayoutCaches 17 | "C:\Program Files\7-Zip\7z" 18 | -xr!obj -xr!bin -xr!.vs -x!*.csproj -x!*.sln -x!*.suo -x!*.user -x!DemoRestriction.cs 19 | 20 | Assets\Plugins 21 | RelationsInspector$(DemoMode).unitypackage 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 49 | 50 | 51 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /ProjectSettings/AudioManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!11 &1 4 | AudioManager: 5 | m_ObjectHideFlags: 0 6 | m_Volume: 1 7 | Rolloff Scale: 1 8 | m_SpeedOfSound: 347 9 | Doppler Factor: 1 10 | Default Speaker Mode: 2 11 | m_DSPBufferSize: 0 12 | m_DisableAudio: 0 13 | -------------------------------------------------------------------------------- /ProjectSettings/DynamicsManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!55 &1 4 | PhysicsManager: 5 | m_ObjectHideFlags: 0 6 | m_Gravity: {x: 0, y: -9.81000042, z: 0} 7 | m_DefaultMaterial: {fileID: 0} 8 | m_BounceThreshold: 2 9 | m_SleepVelocity: .150000006 10 | m_SleepAngularVelocity: .140000001 11 | m_MaxAngularVelocity: 7 12 | m_MinPenetrationForPenalty: .00999999978 13 | m_SolverIterationCount: 6 14 | m_RaycastsHitTriggers: 1 15 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 16 | -------------------------------------------------------------------------------- /ProjectSettings/EditorBuildSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1045 &1 4 | EditorBuildSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_Scenes: [] 8 | -------------------------------------------------------------------------------- /ProjectSettings/EditorSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!159 &1 4 | EditorSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 3 7 | m_ExternalVersionControlSupport: Hidden Meta Files 8 | m_SerializationMode: 2 9 | m_WebSecurityEmulationEnabled: 0 10 | m_WebSecurityEmulationHostUrl: http://www.mydomain.com/mygame.unity3d 11 | m_DefaultBehaviorMode: 0 12 | m_SpritePackerMode: 0 13 | -------------------------------------------------------------------------------- /ProjectSettings/GraphicsSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!30 &1 4 | GraphicsSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_AlwaysIncludedShaders: 8 | - {fileID: 7, guid: 0000000000000000f000000000000000, type: 0} 9 | - {fileID: 10770, guid: 0000000000000000f000000000000000, type: 0} 10 | - {fileID: 10782, guid: 0000000000000000f000000000000000, type: 0} 11 | -------------------------------------------------------------------------------- /ProjectSettings/NavMeshLayers.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!126 &1 4 | NavMeshLayers: 5 | m_ObjectHideFlags: 0 6 | Built-in Layer 0: 7 | name: Default 8 | cost: 1 9 | editType: 2 10 | Built-in Layer 1: 11 | name: Not Walkable 12 | cost: 1 13 | editType: 0 14 | Built-in Layer 2: 15 | name: Jump 16 | cost: 2 17 | editType: 2 18 | User Layer 0: 19 | name: 20 | cost: 1 21 | editType: 3 22 | User Layer 1: 23 | name: 24 | cost: 1 25 | editType: 3 26 | User Layer 2: 27 | name: 28 | cost: 1 29 | editType: 3 30 | User Layer 3: 31 | name: 32 | cost: 1 33 | editType: 3 34 | User Layer 4: 35 | name: 36 | cost: 1 37 | editType: 3 38 | User Layer 5: 39 | name: 40 | cost: 1 41 | editType: 3 42 | User Layer 6: 43 | name: 44 | cost: 1 45 | editType: 3 46 | User Layer 7: 47 | name: 48 | cost: 1 49 | editType: 3 50 | User Layer 8: 51 | name: 52 | cost: 1 53 | editType: 3 54 | User Layer 9: 55 | name: 56 | cost: 1 57 | editType: 3 58 | User Layer 10: 59 | name: 60 | cost: 1 61 | editType: 3 62 | User Layer 11: 63 | name: 64 | cost: 1 65 | editType: 3 66 | User Layer 12: 67 | name: 68 | cost: 1 69 | editType: 3 70 | User Layer 13: 71 | name: 72 | cost: 1 73 | editType: 3 74 | User Layer 14: 75 | name: 76 | cost: 1 77 | editType: 3 78 | User Layer 15: 79 | name: 80 | cost: 1 81 | editType: 3 82 | User Layer 16: 83 | name: 84 | cost: 1 85 | editType: 3 86 | User Layer 17: 87 | name: 88 | cost: 1 89 | editType: 3 90 | User Layer 18: 91 | name: 92 | cost: 1 93 | editType: 3 94 | User Layer 19: 95 | name: 96 | cost: 1 97 | editType: 3 98 | User Layer 20: 99 | name: 100 | cost: 1 101 | editType: 3 102 | User Layer 21: 103 | name: 104 | cost: 1 105 | editType: 3 106 | User Layer 22: 107 | name: 108 | cost: 1 109 | editType: 3 110 | User Layer 23: 111 | name: 112 | cost: 1 113 | editType: 3 114 | User Layer 24: 115 | name: 116 | cost: 1 117 | editType: 3 118 | User Layer 25: 119 | name: 120 | cost: 1 121 | editType: 3 122 | User Layer 26: 123 | name: 124 | cost: 1 125 | editType: 3 126 | User Layer 27: 127 | name: 128 | cost: 1 129 | editType: 3 130 | User Layer 28: 131 | name: 132 | cost: 1 133 | editType: 3 134 | -------------------------------------------------------------------------------- /ProjectSettings/NetworkManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!149 &1 4 | NetworkManager: 5 | m_ObjectHideFlags: 0 6 | m_DebugLevel: 0 7 | m_Sendrate: 15 8 | m_AssetToPrefab: {} 9 | -------------------------------------------------------------------------------- /ProjectSettings/Physics2DSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!19 &1 4 | Physics2DSettings: 5 | m_ObjectHideFlags: 0 6 | m_Gravity: {x: 0, y: -9.81000042} 7 | m_DefaultMaterial: {fileID: 0} 8 | m_VelocityIterations: 8 9 | m_PositionIterations: 3 10 | m_VelocityThreshold: 1 11 | m_MaxLinearCorrection: .200000003 12 | m_MaxAngularCorrection: 8 13 | m_MaxTranslationSpeed: 100 14 | m_MaxRotationSpeed: 360 15 | m_BaumgarteScale: .200000003 16 | m_BaumgarteTimeOfImpactScale: .75 17 | m_TimeToSleep: .5 18 | m_LinearSleepTolerance: .00999999978 19 | m_AngularSleepTolerance: 2 20 | m_RaycastsHitTriggers: 1 21 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 22 | -------------------------------------------------------------------------------- /ProjectSettings/QualitySettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!47 &1 4 | QualitySettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 5 7 | m_CurrentQuality: 3 8 | m_QualitySettings: 9 | - serializedVersion: 2 10 | name: Fastest 11 | pixelLightCount: 0 12 | shadows: 0 13 | shadowResolution: 0 14 | shadowProjection: 1 15 | shadowCascades: 1 16 | shadowDistance: 15 17 | blendWeights: 1 18 | textureQuality: 1 19 | anisotropicTextures: 0 20 | antiAliasing: 0 21 | softParticles: 0 22 | softVegetation: 0 23 | vSyncCount: 0 24 | lodBias: .300000012 25 | maximumLODLevel: 0 26 | particleRaycastBudget: 4 27 | excludedTargetPlatforms: [] 28 | - serializedVersion: 2 29 | name: Fast 30 | pixelLightCount: 0 31 | shadows: 0 32 | shadowResolution: 0 33 | shadowProjection: 1 34 | shadowCascades: 1 35 | shadowDistance: 20 36 | blendWeights: 2 37 | textureQuality: 0 38 | anisotropicTextures: 0 39 | antiAliasing: 0 40 | softParticles: 0 41 | softVegetation: 0 42 | vSyncCount: 0 43 | lodBias: .400000006 44 | maximumLODLevel: 0 45 | particleRaycastBudget: 16 46 | excludedTargetPlatforms: [] 47 | - serializedVersion: 2 48 | name: Simple 49 | pixelLightCount: 1 50 | shadows: 1 51 | shadowResolution: 0 52 | shadowProjection: 1 53 | shadowCascades: 1 54 | shadowDistance: 20 55 | blendWeights: 2 56 | textureQuality: 0 57 | anisotropicTextures: 1 58 | antiAliasing: 0 59 | softParticles: 0 60 | softVegetation: 0 61 | vSyncCount: 0 62 | lodBias: .699999988 63 | maximumLODLevel: 0 64 | particleRaycastBudget: 64 65 | excludedTargetPlatforms: [] 66 | - serializedVersion: 2 67 | name: Good 68 | pixelLightCount: 2 69 | shadows: 2 70 | shadowResolution: 1 71 | shadowProjection: 1 72 | shadowCascades: 2 73 | shadowDistance: 40 74 | blendWeights: 2 75 | textureQuality: 0 76 | anisotropicTextures: 1 77 | antiAliasing: 0 78 | softParticles: 0 79 | softVegetation: 1 80 | vSyncCount: 1 81 | lodBias: 1 82 | maximumLODLevel: 0 83 | particleRaycastBudget: 256 84 | excludedTargetPlatforms: [] 85 | - serializedVersion: 2 86 | name: Beautiful 87 | pixelLightCount: 3 88 | shadows: 2 89 | shadowResolution: 2 90 | shadowProjection: 1 91 | shadowCascades: 2 92 | shadowDistance: 70 93 | blendWeights: 4 94 | textureQuality: 0 95 | anisotropicTextures: 2 96 | antiAliasing: 2 97 | softParticles: 1 98 | softVegetation: 1 99 | vSyncCount: 1 100 | lodBias: 1.5 101 | maximumLODLevel: 0 102 | particleRaycastBudget: 1024 103 | excludedTargetPlatforms: [] 104 | - serializedVersion: 2 105 | name: Fantastic 106 | pixelLightCount: 4 107 | shadows: 2 108 | shadowResolution: 2 109 | shadowProjection: 1 110 | shadowCascades: 4 111 | shadowDistance: 150 112 | blendWeights: 4 113 | textureQuality: 0 114 | anisotropicTextures: 2 115 | antiAliasing: 2 116 | softParticles: 1 117 | softVegetation: 1 118 | vSyncCount: 1 119 | lodBias: 2 120 | maximumLODLevel: 0 121 | particleRaycastBudget: 4096 122 | excludedTargetPlatforms: [] 123 | m_PerPlatformDefaultQuality: 124 | Android: 2 125 | BlackBerry: 2 126 | FlashPlayer: 3 127 | GLES Emulation: 3 128 | PS3: 3 129 | PS4: 3 130 | PSM: 3 131 | PSP2: 3 132 | Samsung TV: 2 133 | Standalone: 3 134 | Tizen: 2 135 | WP8: 3 136 | Web: 3 137 | Windows Store Apps: 3 138 | XBOX360: 3 139 | XboxOne: 3 140 | iPhone: 2 141 | -------------------------------------------------------------------------------- /ProjectSettings/TagManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!78 &1 4 | TagManager: 5 | tags: 6 | - 7 | Builtin Layer 0: Default 8 | Builtin Layer 1: TransparentFX 9 | Builtin Layer 2: Ignore Raycast 10 | Builtin Layer 3: 11 | Builtin Layer 4: Water 12 | Builtin Layer 5: UI 13 | Builtin Layer 6: 14 | Builtin Layer 7: 15 | User Layer 8: 16 | User Layer 9: 17 | User Layer 10: 18 | User Layer 11: 19 | User Layer 12: 20 | User Layer 13: 21 | User Layer 14: 22 | User Layer 15: 23 | User Layer 16: 24 | User Layer 17: 25 | User Layer 18: 26 | User Layer 19: 27 | User Layer 20: 28 | User Layer 21: 29 | User Layer 22: 30 | User Layer 23: 31 | User Layer 24: 32 | User Layer 25: 33 | User Layer 26: 34 | User Layer 27: 35 | User Layer 28: 36 | User Layer 29: 37 | User Layer 30: 38 | User Layer 31: 39 | m_SortingLayers: 40 | - name: Default 41 | userID: 0 42 | uniqueID: 0 43 | locked: 0 44 | -------------------------------------------------------------------------------- /ProjectSettings/TimeManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!5 &1 4 | TimeManager: 5 | m_ObjectHideFlags: 0 6 | Fixed Timestep: .0199999996 7 | Maximum Allowed Timestep: .333333343 8 | m_TimeScale: 1 9 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |

2 | 3 | Logo 4 |
5 |

RelationsInspector

6 | 7 |

8 | An editor extension for the Unity game engine. 9 |
10 | Download from the Asset Store 11 |
12 |
13 | User docs 14 | · 15 | Discussion 16 |

17 |

18 | 19 | 20 | ## About 21 | 22 | This is a node based editor and viewer that can be connected to all kinds of data in your Unity project. Its main advantage is probably the automatic layout of nodes, allowing you to quickly grasp how they are connected. Support exists for [asset references](https://seldomu.github.io/riBackends/AssetReferenceBackend/), [asset dependencies](https://seldomu.github.io/riBackends/AssetReferenceBackend/), [UI events](https://seldomu.github.io/riBackends/UGUIeventBackend/), [playmaker state machines](https://seldomu.github.io/riBackends/PlayMakerFsmCommunicationBackend/) and more, but you can also add your own. 23 | 24 | 25 | ## Usage 26 | 27 | If you simply want to use RelationsInspector, [install it](https://assetstore.unity.com/packages/tools/utilities/relationsinspector-53147) through the asset store. If you want to add support for your use case, [see the documentation](https://github.com/seldomU/RIBackendUtil/wiki/RelationsInspector-Manual#backend-development) for the [utility classes](https://github.com/seldomU/RIBackendUtil). If you want to change the tool's internal library, this repository is for you. 28 | 29 | ### Build 30 | 31 | Run `build.bat` to generate `RIDLLProject\bin\Release\RelationsInspector.dll`. Copy that file to any Unity project that has RelationsInspector already installed, to the folder `Assets\Plugins\Editor\RelationsInspector`. There are two paths that you have to adjust to your environment: 32 | * the path to msbuild.exe in `build.bat` 33 | * the path to your Unity editor in `build.bat` and in `RIDllProject/RelationsInspectorLib.csproj`. Replace the paths containing *Unity 5.5*. 34 | 35 | ## License 36 | 37 | Distributed under the MIT License. See `LICENSE` for more information. 38 | -------------------------------------------------------------------------------- /RIDLLProject/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle( "RelationsInspector" )] 9 | [assembly: AssemblyDescription( "Editor plugin for Unity 4.3 and higher. Graphical visualiztion of relations." )] 10 | [assembly: AssemblyConfiguration( "" )] 11 | [assembly: AssemblyCompany( "seldomU" )] 12 | [assembly: AssemblyProduct( "RelationsInspector" )] 13 | [assembly: AssemblyCopyright( "Copyright © 2016" )] 14 | [assembly: AssemblyTrademark( "" )] 15 | [assembly: AssemblyCulture( "" )] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible( false )] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid( "443be73c-10d9-48b3-9f43-5f22e4c45fa6" )] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | [assembly: AssemblyVersion( "1.1.5" )] 33 | //[assembly: AssemblyFileVersion( "1.0.0.0" )] 34 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/AcceptTargetsAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class AcceptTargetsAttribute : Attribute 7 | { 8 | public Type type; 9 | 10 | public AcceptTargetsAttribute( Type type ) 11 | { 12 | this.type = type; 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/DescriptionAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class DescriptionAttribute : Attribute 7 | { 8 | public string description; 9 | 10 | public DescriptionAttribute( string description ) 11 | { 12 | this.description = description; 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/DocumentationAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class DocumentationAttribute : Attribute 7 | { 8 | public string url; 9 | 10 | public DocumentationAttribute( string url ) 11 | { 12 | this.url = url; 13 | } 14 | } 15 | } 16 | 17 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/HideAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class HideAttribute : Attribute 7 | { 8 | public HideAttribute() 9 | { 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/IGraphBackend.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using UnityEditor; 3 | using System.Collections.Generic; 4 | 5 | namespace RelationsInspector 6 | { 7 | public interface IGraphBackend where T : class 8 | { 9 | void Awake( GetAPI getAPI ); 10 | IEnumerable Init( object target ); 11 | void OnDestroy(); 12 | IEnumerable> GetRelations( T entity ); 13 | void CreateRelation( T source, T target ); 14 | void OnEntitySelectionChange( T[] selection ); 15 | void OnUnitySelectionChange(); 16 | Rect OnGUI(); 17 | 18 | string GetEntityTooltip( T entity ); 19 | string GetTagTooltip( P tag ); 20 | Rect DrawContent( T entity, EntityDrawContext drawContext ); 21 | 22 | void OnEntityContextClick( IEnumerable entities, GenericMenu contextMenu ); 23 | void OnRelationContextClick( Relation relation, GenericMenu contextMenu ); 24 | Color GetRelationColor( P relationTagValue ); 25 | void OnCommand( string command ); 26 | } 27 | 28 | internal interface IGraphBackend2 where T : class 29 | { 30 | // initialize the backend object 31 | void Awake( GetAPI getAPI ); 32 | IEnumerable Init( object target ); 33 | void OnDestroy(); 34 | IEnumerable> GetRelations( T entity ); 35 | void CreateRelation( T source, T target ); 36 | void OnEntitySelectionChange( T[] selection ); 37 | void OnUnitySelectionChange(); 38 | Rect OnGUI(); 39 | 40 | string GetEntityTooltip( T entity ); 41 | string GetTagTooltip( P tag ); 42 | Rect DrawContent( T entity, EntityDrawContext drawContext ); 43 | 44 | void OnEntityContextClick( IEnumerable entities, GenericMenu contextMenu ); 45 | void OnRelationContextClick( Relation relation, GenericMenu contextMenu ); 46 | Color GetRelationColor( P relationTagValue ); 47 | void OnCommand( string command ); 48 | } 49 | 50 | } 51 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/IGraphBackendInternal.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using UnityEditor; 3 | using UnityEngine; 4 | 5 | namespace RelationsInspector 6 | { 7 | internal interface IGraphBackendInternal where T : class 8 | { 9 | System.Type GetDecoratedType(); 10 | void Awake( GetAPI getAPI ); 11 | IEnumerable Init( object target ); 12 | void OnDestroy(); 13 | IEnumerable> GetRelations( T entity ); 14 | void CreateRelation( T source, T target ); 15 | void OnEntitySelectionChange( T[] selection ); 16 | void OnUnitySelectionChange(); 17 | Rect OnGUI(); 18 | 19 | string GetEntityTooltip( T entity ); 20 | string GetTagTooltip( P tag ); 21 | Rect DrawContent( T entity, EntityDrawContext drawContext ); 22 | 23 | void OnEntityContextClick( IEnumerable entities, GenericMenu menu ); 24 | void OnRelationContextClick( Relation relation, GenericMenu menu ); 25 | Color GetRelationColor( P relationTagValue ); 26 | void OnCommand( string command ); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/IconAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class IconAttribute : Attribute 7 | { 8 | public string iconPath; 9 | 10 | public IconAttribute( string iconPath ) 11 | { 12 | this.iconPath = iconPath; 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/TitleAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class TitleAttribute : Attribute 7 | { 8 | public string title; 9 | 10 | public TitleAttribute( string title ) 11 | { 12 | this.title = title; 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /RIDLLProject/Backend/VersionAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class VersionAttribute : Attribute 7 | { 8 | public string version; 9 | 10 | public VersionAttribute( string version ) 11 | { 12 | this.version = version; 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /RIDLLProject/DemoRestriction.cs: -------------------------------------------------------------------------------- 1 | #if RIDEMO 2 | using UnityEngine; 3 | using UnityEditor; 4 | 5 | namespace RelationsInspector 6 | { 7 | static class DemoRestriction 8 | { 9 | static int inputEventCount = 0; 10 | const int inputEventCountThreshold = 500; 11 | 12 | public static void Run() 13 | { 14 | 15 | switch (Event.current.type) 16 | { 17 | case EventType.MouseUp: 18 | case EventType.MouseDown: 19 | inputEventCount++; 20 | break; 21 | } 22 | 23 | if (inputEventCount >= inputEventCountThreshold) 24 | { 25 | inputEventCount = 0; 26 | bool openStore = EditorUtility.DisplayDialog("Demo", "Thanks for trying the RelationsInspector demo. It is not restricted, but to use the tool permanently, you have to buy the full version.", "To the store", "Not now" ); 27 | if(openStore) 28 | UnityEditorInternal.AssetStore.Open( ProjectSettings.StoreDemoURL ); 29 | } 30 | } 31 | 32 | public static void OnEnable() 33 | { 34 | inputEventCount = GUIUtil.GetPrefsInt( "DemoActions", 0 ); 35 | } 36 | 37 | public static void OnDestroy() 38 | { 39 | GUIUtil.SetPrefsInt( "DemoActions", inputEventCount ); 40 | } 41 | } 42 | } 43 | #endif //RIDEMO 44 | -------------------------------------------------------------------------------- /RIDLLProject/EdgePlacement/EdgePlacement.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | public delegate EdgePlacement EdgePlacementProvider( Rect sourceRect, Rect targetRect, float gapSize ); 6 | 7 | public struct EdgePlacement 8 | { 9 | public Vector2 startPos; 10 | public Vector2 endPos; 11 | public Vector2 startNormal; 12 | public Vector2 endNormal; 13 | 14 | public EdgePlacement( Vector2 startPos, Vector2 endPos, Vector2 startNormal, Vector2 endNormal ) 15 | { 16 | this.startPos = startPos; 17 | this.endPos = endPos; 18 | this.startNormal = startNormal; 19 | this.endNormal = endNormal; 20 | } 21 | 22 | public static EdgePlacement zero = new EdgePlacement( Vector2.zero, Vector2.zero, Vector2.one, Vector2.one ); 23 | 24 | public EdgePlacement Swap() 25 | { 26 | return new EdgePlacement( endPos, startPos, endNormal, startNormal ); 27 | } 28 | } 29 | } 30 | 31 | -------------------------------------------------------------------------------- /RIDLLProject/EdgePlacement/StraightCirclePlacementProvider.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | public class StraightCirclePlacementProvider 6 | { 7 | public static EdgePlacement GetEdgePlacement( Rect sourceRect, Rect targetRect, float gapSize ) 8 | { 9 | if ( sourceRect == targetRect ) 10 | return GetSelfEdgePlacement( sourceRect ); 11 | 12 | var sourceCenter = sourceRect.center; 13 | var sourceRadius = sourceRect.width / 2; 14 | 15 | var targetCenter = targetRect.center; 16 | var targetRadius = targetRect.width / 2; 17 | 18 | var direction = ( targetCenter - sourceCenter ).normalized; 19 | 20 | var startPos = sourceCenter + direction * ( sourceRadius + gapSize ); 21 | var endPos = targetCenter - direction * ( targetRadius + gapSize ); 22 | return new EdgePlacement( startPos, endPos, Vector2.zero, Vector2.zero ); 23 | } 24 | 25 | static EdgePlacement GetSelfEdgePlacement( Rect rect ) 26 | { 27 | var startPos = new Vector2( rect.xMin, rect.center.y ); 28 | var endPos = new Vector2( rect.center.x, rect.yMin ); 29 | 30 | return new EdgePlacement( startPos, endPos, Vector2.zero, Vector2.zero ); 31 | } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /RIDLLProject/EdgePlacement/StraightRectPlacementProvider.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | public class StraightRectPlacementProvider 6 | { 7 | static float selfEdgeOffset = 10; // edge anchor distances from rect corner 8 | 9 | public static EdgePlacement GetEdgePlacement( Rect sourceRect, Rect targetRect, float gapSize ) 10 | { 11 | if ( sourceRect == targetRect ) 12 | return GetSelfEdgePlacement( sourceRect ); 13 | 14 | var sourceToTarget = ( targetRect.center - sourceRect.center ).normalized; 15 | Tuple start = GetExitPoint( sourceRect, sourceToTarget, gapSize ); 16 | Tuple end = GetExitPoint( targetRect, -sourceToTarget, gapSize ); 17 | return new EdgePlacement( start._1, end._1, start._2, end._2 ); 18 | } 19 | 20 | static Tuple GetExitPoint( Rect rect, Vector2 direction, float gapSize ) 21 | { 22 | // how many units do we have to go from rect center along direction until we hit x and y bounds 23 | // if direction is horizontal/vertical, one of them is never reached. we use float.MaxValue there, which will always lose the comparison 24 | float xScale = direction.x == 0 ? float.MaxValue : Mathf.Abs( rect.width / 2 / direction.x ); 25 | float yScale = direction.y == 0 ? float.MaxValue : Mathf.Abs( rect.height / 2 / direction.y ); 26 | 27 | bool useXscale = xScale < yScale; 28 | Vector2 normal = useXscale ? Vector2.right : Vector2.up; 29 | normal *= ( useXscale ? direction.x > 0 : direction.y > 0 ) ? 1 : -1; 30 | Vector2 exitPoint = rect.center + direction * Mathf.Min( xScale, yScale ); 31 | exitPoint += direction * gapSize; 32 | return new Tuple( exitPoint, normal ); 33 | } 34 | 35 | static EdgePlacement GetSelfEdgePlacement( Rect rect ) 36 | { 37 | Vector2 start = new Vector2( rect.xMin, rect.yMin + selfEdgeOffset ); 38 | Vector2 end = new Vector2( rect.xMin + selfEdgeOffset, rect.yMin ); 39 | return new EdgePlacement( start, end, -Vector2.right, -Vector2.up ); 40 | } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /RIDLLProject/Graph/FoldUtil.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace RelationsInspector 7 | { 8 | class SubGraph 9 | { 10 | public List entryPoints = new List(); 11 | public HashSet elements = new HashSet(); 12 | public int numSeeds; 13 | public SubGraph() { } 14 | } 15 | 16 | class FoldUtil 17 | { 18 | public static List> Split( Graph graph, T root, Func isGraphSeed ) where T : class 19 | { 20 | var rootNeighbors = graph.GetNeighborsExceptSelf( root ); 21 | var subGraphs = new List>(); 22 | foreach ( var seed in rootNeighbors ) 23 | { 24 | var containingSubGraphs = subGraphs.Where( sg => sg.elements.Contains( seed ) ); 25 | int numSG = containingSubGraphs.Count(); 26 | if ( numSG > 1 ) 27 | { 28 | throw new Exception( "found vertex in more than one subgraph" ); 29 | } 30 | else if ( numSG == 1 ) 31 | { 32 | containingSubGraphs.Single().entryPoints.Add( seed ); 33 | continue; 34 | } 35 | else 36 | subGraphs.Add( FillSubGraph( seed, graph, root, isGraphSeed ) ); 37 | } 38 | return subGraphs; 39 | } 40 | 41 | private static SubGraph FillSubGraph( T seed, Graph graph, T root, Func isGraphSeed ) where T : class 42 | { 43 | 44 | var subGraph = new SubGraph(); 45 | subGraph.entryPoints.Add( seed ); 46 | 47 | var neighbors = new HashSet() { seed }; 48 | 49 | while ( neighbors.Any() ) 50 | { 51 | var item = neighbors.First(); 52 | neighbors.Remove( item ); 53 | if ( subGraph.elements.Contains( item ) ) 54 | continue; 55 | 56 | subGraph.elements.Add( item ); 57 | subGraph.numSeeds += isGraphSeed( item ) ? 1 : 0; 58 | neighbors.UnionWith( graph.GetNeighbors( item ).Except( new[] { root } ) ); 59 | } 60 | return subGraph; 61 | } 62 | 63 | public static IEnumerable GetFoldVertices( Graph graph, T foldEntity, Func isGraphSeed ) where T : class 64 | { 65 | var subGraphs = Split( graph, foldEntity, isGraphSeed ); 66 | if ( !subGraphs.Any( sub => sub.numSeeds > 0 ) ) 67 | return Enumerable.Empty(); 68 | 69 | return subGraphs 70 | .Where( sub => sub.numSeeds == 0 ) 71 | .Where( sub => sub.entryPoints.Any( entry => graph.CanRegenerate( foldEntity, entry ) ) ) 72 | .SelectMany( sub => sub.elements ); 73 | } 74 | 75 | public static void Fold( Graph graph, T foldEntity, Func isGraphSeed ) where T : class 76 | { 77 | var removeEntities = GetFoldVertices( graph, foldEntity, isGraphSeed ); 78 | 79 | if ( removeEntities.Any() ) 80 | graph.VerticesData[ foldEntity ].unexplored = true; 81 | 82 | foreach ( var ent in removeEntities ) 83 | graph.RemoveVertex( ent ); 84 | } 85 | } 86 | } 87 | -------------------------------------------------------------------------------- /RIDLLProject/Graph/GraphExtensions.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Linq; 3 | 4 | namespace RelationsInspector 5 | { 6 | public static class GraphExtensions 7 | { 8 | public static IEnumerable GetNeighbors( this Graph graph, T vertex ) where T : class 9 | { 10 | return graph.GetParents( vertex ).Concat( graph.GetChildren( vertex ) ); 11 | } 12 | 13 | public static IEnumerable GetNeighborsExceptSelf( this Graph graph, T vertex ) where T : class 14 | { 15 | return graph.GetParentsExceptSelf( vertex ).Concat( graph.GetChildrenExceptSelf( vertex ) ); 16 | } 17 | 18 | public static IEnumerable GetChildren( this Graph graph, T vertex ) where T : class 19 | { 20 | if ( !graph.Vertices.Contains( vertex ) ) 21 | return Enumerable.Empty(); 22 | 23 | return graph.VerticesData[ vertex ].OutEdges.Get().Select( e => e.Target ); 24 | } 25 | 26 | public static IEnumerable GetChildrenExceptSelf( this Graph graph, T vertex ) where T : class 27 | { 28 | return graph.GetChildren( vertex ).Where( c => c != vertex ); 29 | } 30 | 31 | public static IEnumerable GetParents( this Graph graph, T vertex ) where T : class 32 | { 33 | if ( !graph.Vertices.Contains( vertex ) ) 34 | return Enumerable.Empty(); 35 | 36 | return graph.VerticesData[ vertex ].InEdges.Get().Select( e => e.Source ); 37 | } 38 | 39 | public static IEnumerable GetParentsExceptSelf( this Graph graph, T vertex ) where T : class 40 | { 41 | return graph.GetParents( vertex ).Where( p => p != vertex ); 42 | } 43 | 44 | public static IEnumerable> GetEdges( this Graph graph, T vertex ) where T : class 45 | { 46 | return graph.GetInEdges( vertex ).Concat( graph.GetOutEdges( vertex ) ); 47 | } 48 | 49 | public static IEnumerable> GetOutEdges( this Graph graph, T vertex ) where T : class 50 | { 51 | if ( !graph.Vertices.Contains( vertex ) ) 52 | return Enumerable.Empty>(); 53 | 54 | return graph.VerticesData[ vertex ].OutEdges.Get(); 55 | } 56 | 57 | public static IEnumerable> GetInEdges( this Graph graph, T vertex ) where T : class 58 | { 59 | if ( !graph.Vertices.Contains( vertex ) ) 60 | return Enumerable.Empty>(); 61 | 62 | return graph.VerticesData[ vertex ].InEdges.Get(); 63 | } 64 | 65 | 66 | public static bool IsMultipleTrees( this Graph graph ) where T : class 67 | { 68 | var roots = graph.RootVertices; 69 | 70 | // no roots -> guaranteed cycle 71 | if ( !roots.Any() ) 72 | return false; 73 | 74 | var visited = new HashSet(); 75 | var unexplored = new HashSet( roots ); 76 | 77 | while ( unexplored.Any() ) 78 | { 79 | var item = unexplored.First(); 80 | unexplored.Remove( item ); 81 | visited.Add( item ); 82 | 83 | var successors = graph.GetChildrenExceptSelf( item ); // ignore self edges 84 | 85 | if ( successors.Any( v => visited.Contains( v ) || unexplored.Contains( v ) ) ) 86 | return false; 87 | 88 | unexplored.UnionWith( successors ); 89 | } 90 | 91 | // subgraphs that have no roots (and thus contain cycles) haven't been visited yet 92 | // if any exists, this is not a tree 93 | return graph.Vertices.All( v => visited.Contains( v ) ); 94 | } 95 | } 96 | } 97 | -------------------------------------------------------------------------------- /RIDLLProject/Graph/Relation.cs: -------------------------------------------------------------------------------- 1 | 2 | using System; 3 | 4 | namespace RelationsInspector 5 | { 6 | public class Relation : IEquatable> where T : class 7 | { 8 | public T Source { get; private set; } 9 | public T Target { get; private set; } 10 | public P Tag { get; private set; } 11 | public bool IsSelfRelation { get { return Source == Target; } } 12 | 13 | public Relation( T source, T target, P tag ) 14 | { 15 | this.Source = source; 16 | this.Target = target; 17 | this.Tag = tag; 18 | } 19 | 20 | public T Opposite( T entity ) 21 | { 22 | if ( entity == Source ) return Target; 23 | if ( entity == Target ) return Source; 24 | throw new System.ArgumentException( "entity is not part of the relation" ); 25 | } 26 | 27 | public override int GetHashCode() 28 | { 29 | int hash = 13; 30 | hash = ( hash * 7 ) + Source.GetHashCode(); 31 | hash = ( hash * 7 ) + Target.GetHashCode(); 32 | hash = ( hash * 7 ) + Tag.GetHashCode(); 33 | return hash; 34 | } 35 | 36 | public bool Equals( Relation other ) 37 | { 38 | return ( 39 | other != null && 40 | Source.Equals( other.Source ) && 41 | Target.Equals( other.Target ) && 42 | Tag.Equals( other.Tag ) ); 43 | } 44 | 45 | public override bool Equals( object otherObj ) 46 | { 47 | var otherRelation = otherObj as Relation; 48 | return ( otherRelation == null ) ? false : Equals( otherRelation ); 49 | } 50 | 51 | public bool Matches( T source, T target, P tag ) 52 | { 53 | return Source == source && Target == target && ( Tag == null && tag == null || Tag != null && Tag.Equals( tag ) ); 54 | } 55 | 56 | public Relation Copy() 57 | { 58 | return new Relation( Source, Target, Tag ); 59 | } 60 | 61 | public override string ToString() 62 | { 63 | return string.Format( "source: {0}, target: {1}, tag: {2}, hash {3}", Source, Target, Tag, GetHashCode() ); 64 | } 65 | } 66 | } 67 | -------------------------------------------------------------------------------- /RIDLLProject/Graph/VertexData.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace RelationsInspector 6 | { 7 | public class VertexData where T : class 8 | { 9 | T subject; 10 | public Vector2 pos; 11 | public bool unexplored; 12 | public EdgeSet InEdges { get; private set; } 13 | public EdgeSet OutEdges { get; private set; } 14 | 15 | public VertexData( T subject ) 16 | { 17 | this.subject = subject; 18 | pos = Vector2.zero; 19 | InEdges = new EdgeSet( subject, false ); 20 | OutEdges = new EdgeSet( subject, true ); 21 | } 22 | 23 | public IEnumerable GetCorrespondents() 24 | { 25 | return InEdges.GetCorrespondents().Union( OutEdges.GetCorrespondents() ); 26 | } 27 | } 28 | 29 | // incomming or outgoing edges of one vertex 30 | public class EdgeSet where T : class 31 | { 32 | // the vertex this edgeset belongs to 33 | private T subject; 34 | 35 | // if true, byCorespondent contains outgoing edges. if false, they are incomming edges 36 | private bool isSource; 37 | 38 | // per corresponent vertex, the set of edges between subject and the vertex. 39 | // depending on isSource they are either outgoing or incomming, from subject's PoV 40 | private Dictionary>> byCorespondent = new Dictionary>>(); 41 | 42 | // ctor 43 | public EdgeSet( T subject, bool isSource ) 44 | { 45 | this.subject = subject; 46 | this.isSource = isSource; 47 | } 48 | 49 | // returns all edges between subject and corresponent 50 | // returns ALL edges if correspondent is null 51 | public IEnumerable> Get( T correspondent = null ) 52 | { 53 | if ( correspondent == null ) 54 | return byCorespondent.Values.SelectMany( x => x ); 55 | 56 | if ( !byCorespondent.ContainsKey( correspondent ) ) 57 | return Enumerable.Empty>(); 58 | 59 | return byCorespondent[ correspondent ]; 60 | } 61 | 62 | // returns all edge sets 63 | public IEnumerable>> GetSets() 64 | { 65 | return byCorespondent.Values; 66 | } 67 | 68 | // returns all vertices this edgeset knows 69 | public IEnumerable GetCorrespondents() 70 | { 71 | return byCorespondent.Where( pair => pair.Value.Any() ).Select( pair => pair.Key ); 72 | } 73 | 74 | // add edge to the set 75 | public void Add( Relation relation ) 76 | { 77 | if ( relation == null ) 78 | throw new System.ArgumentNullException(); 79 | 80 | // make sure the subject is part of the edge 81 | // and in the expected role 82 | if ( isSource && relation.Source != subject || !isSource && relation.Target != subject ) 83 | throw new System.ArgumentException( "Subject does not fill the expect role in edge." ); 84 | 85 | var correspondent = isSource ? relation.Target : relation.Source; 86 | 87 | // ensure that the set exists 88 | if ( !byCorespondent.ContainsKey( correspondent ) ) 89 | byCorespondent[ correspondent ] = new HashSet>(); 90 | 91 | // add the edge 92 | byCorespondent[ correspondent ].Add( relation ); 93 | } 94 | 95 | // remove edge from the set 96 | public void Remove( Relation edge ) 97 | { 98 | if ( edge == null ) 99 | throw new System.ArgumentNullException(); 100 | 101 | var correspondent = isSource ? edge.Target : edge.Source; 102 | 103 | if ( !byCorespondent.ContainsKey( correspondent ) ) 104 | throw new System.ArgumentException( "Edge correspondent unknown." ); 105 | 106 | if ( !byCorespondent[ correspondent ].Remove( edge ) ) 107 | throw new System.ArgumentException( "Edge not found." ); 108 | } 109 | } 110 | } 111 | -------------------------------------------------------------------------------- /RIDLLProject/Layout/LayoutParams.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace RelationsInspector 3 | { 4 | [System.Serializable] 5 | internal class LayoutTweenParameters 6 | { 7 | public float maxFrameDuration = 0.004f; // seconds 8 | public float vertexPosTweenDuration = 0.4f; // seconds 9 | public float vertexPosTweenUpdateInterval = 0.25f; // seconds 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /RIDLLProject/Layout/LayoutType.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace RelationsInspector 3 | { 4 | public enum LayoutType { Graph, Tree } 5 | } 6 | -------------------------------------------------------------------------------- /RIDLLProject/Log.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | internal static class Log 6 | { 7 | enum LogType { Message, Warning, Error } // exceptions too? 8 | 9 | public static void Message( string message ) 10 | { 11 | LogItem( LogType.Message, message ); 12 | } 13 | 14 | public static void Warning( string warning ) 15 | { 16 | LogItem( LogType.Warning, warning ); 17 | } 18 | 19 | public static void Error( string error ) 20 | { 21 | LogItem( LogType.Error, error ); 22 | } 23 | 24 | static void LogItem( LogType type, string item ) 25 | { 26 | if ( !Settings.Instance.logToConsole ) 27 | return; 28 | 29 | string prefix = "Relations inspector: "; 30 | switch ( type ) 31 | { 32 | case LogType.Message: 33 | Debug.Log( prefix + item ); 34 | break; 35 | 36 | case LogType.Warning: 37 | Debug.LogWarning( prefix + item ); 38 | break; 39 | 40 | case LogType.Error: 41 | Debug.LogError( prefix + item ); 42 | break; 43 | } 44 | } 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /RIDLLProject/RIStateHistory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | using UnityEditor; 5 | using System.Linq; 6 | using RelationsInspector.Extensions; 7 | 8 | namespace RelationsInspector 9 | { 10 | struct RIState 11 | { 12 | public HashSet targets; 13 | public Type backendType; 14 | 15 | public RIState( IEnumerable targets, Type backendType ) 16 | { 17 | this.targets = targets.ToHashSet(); 18 | this.backendType = backendType; 19 | } 20 | 21 | public override string ToString() 22 | { 23 | return targets.ToDelimitedString() + " " + backendType.Name; 24 | } 25 | 26 | public override bool Equals( object obj ) 27 | { 28 | if ( !( obj is RIState ) ) 29 | return false; 30 | 31 | var other = (RIState) obj; 32 | return targets.SetEquals( other.targets ) && backendType == other.backendType; 33 | } 34 | 35 | public override int GetHashCode() 36 | { 37 | int hash = 23; 38 | hash = hash * 17 + backendType.GetHashCode(); 39 | foreach ( var t in targets ) 40 | hash = hash * 17 + t.GetHashCode(); 41 | return hash; 42 | } 43 | } 44 | 45 | class RIStateHistory 46 | { 47 | List stateHistory = new List(); 48 | int pointer; 49 | 50 | public void RegisterState( IEnumerable targets, Type backendType ) 51 | { 52 | if ( targets == null || !targets.Any() ) 53 | return; 54 | 55 | // remove anything after pointer 56 | if ( stateHistory.Count > pointer + 1 ) 57 | stateHistory.RemoveRange( pointer + 1, stateHistory.Count - 1 - pointer ); 58 | 59 | var state = new RIState( targets, backendType ); 60 | stateHistory.RemoveWhere( x => x.Equals( state ) ); 61 | stateHistory.Add( state ); 62 | pointer = stateHistory.Count - 1; 63 | } 64 | 65 | public void RegisterBackendChange( Type backendType ) 66 | { 67 | if ( !stateHistory.Any() ) 68 | return; 69 | 70 | RegisterState( stateHistory[ pointer ].targets, backendType ); 71 | } 72 | 73 | public bool HasPrev() 74 | { 75 | return pointer > 0; 76 | } 77 | 78 | public RIState GetPreviousState() 79 | { 80 | pointer--; 81 | return GetTargetsAtPointer(); 82 | } 83 | 84 | public bool HasNext() 85 | { 86 | return pointer < stateHistory.Count - 1; 87 | } 88 | 89 | public RIState GetNextState() 90 | { 91 | pointer++; 92 | return GetTargetsAtPointer(); 93 | } 94 | 95 | RIState GetTargetsAtPointer() 96 | { 97 | if ( !stateHistory.Any() ) 98 | throw new Exception( "There is no state history" ); 99 | 100 | pointer = Mathf.Clamp( pointer, 0, stateHistory.Count - 1 ); 101 | return stateHistory[ pointer ]; 102 | } 103 | 104 | public void OnGUI( Action setTargets ) 105 | { 106 | bool backButtonEnabled = pointer > 0; 107 | bool nextButtonEnabled = pointer < stateHistory.Count - 1; 108 | bool contextEnabaled = GUI.enabled; 109 | 110 | GUI.enabled = backButtonEnabled; 111 | if ( GUILayout.Button( new GUIContent( SkinManager.GetSkin().prevIcon, "Back to previous graph" ), EditorStyles.toolbarButton ) ) 112 | { 113 | var state = GetPreviousState(); 114 | setTargets( state.targets.ToArray(), state.backendType ); 115 | } 116 | 117 | GUI.enabled = nextButtonEnabled; 118 | if ( GUILayout.Button( new GUIContent( SkinManager.GetSkin().nextIcon, "Forward to next graph" ), EditorStyles.toolbarButton ) ) 119 | { 120 | var state = GetNextState(); 121 | setTargets( state.targets.ToArray(), state.backendType ); 122 | } 123 | 124 | GUI.enabled = contextEnabaled; 125 | } 126 | 127 | public override string ToString() 128 | { 129 | var sb = new System.Text.StringBuilder(); 130 | foreach ( var state in stateHistory ) 131 | { 132 | sb.AppendLine( state.ToString() ); 133 | } 134 | sb.AppendLine( "pointer at pos" + pointer ); 135 | return sb.ToString(); 136 | } 137 | } 138 | } 139 | -------------------------------------------------------------------------------- /RIDLLProject/RelationDrawer/RelationDrawUtil.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using UnityEditor; 3 | using RelationsInspector.Extensions; 4 | 5 | namespace RelationsInspector 6 | { 7 | public class RelationDrawUtil 8 | { 9 | internal static void DrawRotatedTexture( Texture2D texture, Vector2 pivot, Vector2 scale, float rotation, Color color ) 10 | { 11 | var rect = Util.CenterRect( pivot, scale ); 12 | rotation *= Mathf.Rad2Deg; 13 | GUIUtility.RotateAroundPivot( rotation, pivot ); 14 | 15 | var colorBackup = GUI.color; 16 | GUI.color = color; 17 | GUI.DrawTexture( rect, texture, ScaleMode.StretchToFill, true ); 18 | GUI.color = colorBackup; 19 | 20 | GUI.matrix = Matrix4x4.identity; 21 | } 22 | 23 | internal static void DrawRotatedRect( Rect rect, float rotation, Color color ) 24 | { 25 | GUIUtility.RotateAroundPivot( rotation * Mathf.Rad2Deg, rect.center ); 26 | EditorGUI.DrawRect( rect, color ); 27 | GUI.matrix = Matrix4x4.identity; 28 | } 29 | 30 | internal static void DrawRotatedRectGL( Rect rect, float rotation, Color color ) 31 | { 32 | GLMaterials.defaultMat.SetPass( 0 ); // set the material 33 | 34 | GL.Begin( GL.QUADS ); 35 | GL.Color( color ); 36 | foreach ( var vertex in rect.Vertices() ) 37 | { 38 | var rotated = vertex.RotateAround( rect.center, rotation ); 39 | GL.Vertex( rotated ); 40 | } 41 | GL.End(); 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /RIDLLProject/RelationsInspectorAPI/APIv1Implementation.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | 5 | namespace RelationsInspector 6 | { 7 | internal class APIv1Implementation : RelationsInspectorAPI 8 | { 9 | RIInternal internalAPI; 10 | 11 | internal APIv1Implementation( RIInternal internalAPI ) 12 | { 13 | this.internalAPI = internalAPI; 14 | } 15 | 16 | // draw a fresh view of the graph 17 | public void Repaint() 18 | { 19 | internalAPI.Repaint(); 20 | } 21 | 22 | // rebuild the graph from the current targets 23 | public void Rebuild() 24 | { 25 | internalAPI.Rebuild(); 26 | } 27 | 28 | // relayout the current graph 29 | public void Relayout() 30 | { 31 | internalAPI.Relayout(); 32 | } 33 | 34 | // manipulate the graph through targets 35 | public void ResetTargets( object[] targets, bool delayed = true ) 36 | { 37 | internalAPI.ResetTargets( targets, delayed ); 38 | } 39 | 40 | public void ResetTargets( object[] targets, Type backendType, bool delayed = true ) 41 | { 42 | internalAPI.ResetTargets( targets, backendType, delayed ); 43 | } 44 | 45 | // if a graph exists, add targets. else create a new one from the targets 46 | public void AddTargets( object[] targets, bool delayed = true ) 47 | { 48 | internalAPI.AddTargets( targets, Vector2.zero, delayed ); 49 | } 50 | 51 | public object[] GetTargets() 52 | { 53 | return internalAPI.GetTargets(); 54 | } 55 | 56 | public IEnumerable GetEntities() 57 | { 58 | return internalAPI.GetEntities(); 59 | } 60 | 61 | public IEnumerable GetRelations() 62 | { 63 | return internalAPI.GetRelations(); 64 | } 65 | 66 | // manipulate the graph directly 67 | public void AddEntity( object entity, Vector2 position, bool delayed = true ) 68 | { 69 | internalAPI.AddEntity( entity, position, delayed ); 70 | } 71 | 72 | public void RemoveEntity( object entity, bool delayed = true ) 73 | { 74 | internalAPI.RemoveEntity( entity, delayed ); 75 | } 76 | 77 | public void ExpandEntity( object entity, bool delayed = true ) 78 | { 79 | internalAPI.ExpandEntity( entity, delayed ); 80 | } 81 | 82 | public void FoldEntity( object entity, bool delayed = true ) 83 | { 84 | internalAPI.FoldEntity( entity, delayed ); 85 | } 86 | 87 | public void InitRelation( object[] sourceEntities, bool delayed = true ) 88 | { 89 | internalAPI.InitRelation( sourceEntities, delayed ); 90 | } 91 | 92 | public object[] FindRelations( object entity ) 93 | { 94 | return internalAPI.FindRelations( entity ); 95 | } 96 | 97 | public void AddRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ) 98 | { 99 | internalAPI.AddRelation( sourceEntity, targetEntity, tag, delayed ); 100 | } 101 | 102 | public void RemoveRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ) 103 | { 104 | internalAPI.RemoveRelation( sourceEntity, targetEntity, tag, delayed ); 105 | } 106 | 107 | // enforce backend selection 108 | public void SetBackend( Type backendType, bool delayed = true ) 109 | { 110 | internalAPI.SetBackend( backendType, delayed ); 111 | } 112 | 113 | public void SelectEntityNodes( Predicate doSelect, bool delayed = true ) 114 | { 115 | internalAPI.SelectEntityNodes( doSelect, delayed ); 116 | } 117 | 118 | public RelationInspectorSkin GetSkin() 119 | { 120 | return SkinManager.GetSkin(); 121 | } 122 | } 123 | } 124 | -------------------------------------------------------------------------------- /RIDLLProject/RelationsInspectorAPI/APIv2Implementation.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | 5 | namespace RelationsInspector 6 | { 7 | internal class APIv2Implementation : RelationsInspectorAPI2 8 | { 9 | RIInternal internalAPI; 10 | 11 | internal APIv2Implementation( RIInternal internalAPI ) 12 | { 13 | this.internalAPI = internalAPI; 14 | } 15 | 16 | // draw a fresh view of the graph 17 | public void Repaint() 18 | { 19 | internalAPI.Repaint(); 20 | } 21 | 22 | // rebuild the graph from the current targets 23 | public void Rebuild() 24 | { 25 | internalAPI.Rebuild(); 26 | } 27 | 28 | // relayout the current graph 29 | public void Relayout() 30 | { 31 | internalAPI.Relayout(); 32 | } 33 | 34 | // manipulate the graph through targets 35 | public void ResetTargets( object[] targets, bool delayed = true ) 36 | { 37 | internalAPI.ResetTargets( targets, delayed ); 38 | } 39 | 40 | public void ResetTargets( object[] targets, Type backendType, bool delayed = true ) 41 | { 42 | internalAPI.ResetTargets( targets, backendType, delayed ); 43 | } 44 | 45 | // if a graph exists, add targets. else create a new one from the targets 46 | public void AddTargets( object[] targets, bool delayed = true ) 47 | { 48 | internalAPI.AddTargets( targets, Vector2.zero, delayed ); 49 | } 50 | 51 | public object[] GetTargets() 52 | { 53 | return internalAPI.GetTargets(); 54 | } 55 | 56 | public IEnumerable GetEntities() 57 | { 58 | return internalAPI.GetEntities(); 59 | } 60 | 61 | public IEnumerable GetRelations() 62 | { 63 | return internalAPI.GetRelations(); 64 | } 65 | 66 | // manipulate the graph directly 67 | public void AddEntity( object entity, Vector2 position, bool delayed = true ) 68 | { 69 | internalAPI.AddEntity( entity, position, delayed ); 70 | } 71 | 72 | public void RemoveEntity( object entity, bool delayed = true ) 73 | { 74 | internalAPI.RemoveEntity( entity, delayed ); 75 | } 76 | 77 | public void ExpandEntity( object entity, bool delayed = true ) 78 | { 79 | internalAPI.ExpandEntity( entity, delayed ); 80 | } 81 | 82 | public void FoldEntity( object entity, bool delayed = true ) 83 | { 84 | internalAPI.FoldEntity( entity, delayed ); 85 | } 86 | 87 | public void InitRelation( object[] sourceEntities, bool delayed = true ) 88 | { 89 | internalAPI.InitRelation( sourceEntities, delayed ); 90 | } 91 | 92 | public object[] FindRelations( object entity ) 93 | { 94 | return internalAPI.FindRelations( entity ); 95 | } 96 | 97 | public void AddRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ) 98 | { 99 | internalAPI.AddRelation( sourceEntity, targetEntity, tag, delayed ); 100 | } 101 | 102 | public void RemoveRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ) 103 | { 104 | internalAPI.RemoveRelation( sourceEntity, targetEntity, tag, delayed ); 105 | } 106 | 107 | // enforce backend selection 108 | public void SetBackend( Type backendType, bool delayed = true ) 109 | { 110 | internalAPI.SetBackend( backendType, delayed ); 111 | } 112 | 113 | public void SelectEntityNodes( Predicate doSelect, bool delayed = true ) 114 | { 115 | internalAPI.SelectEntityNodes( doSelect, delayed ); 116 | } 117 | 118 | public RelationInspectorSkin GetSkin() 119 | { 120 | return SkinManager.GetSkin(); 121 | } 122 | } 123 | } 124 | -------------------------------------------------------------------------------- /RIDLLProject/RelationsInspectorAPI/IRelationsInspectorAPI.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | public interface RelationsInspectorAPI 7 | { 8 | // draw a fresh view of the graph 9 | void Repaint(); 10 | 11 | // rebuild the graph from its current target objects 12 | void Rebuild(); 13 | 14 | // redo the layout on the current graph 15 | void Relayout(); 16 | 17 | // enforce backend selection 18 | void SetBackend( System.Type backendType, bool delayed = true ); 19 | 20 | // manipulate the graph through targets 21 | void ResetTargets( object[] targets, bool delayed = true ); 22 | void ResetTargets( object[] targets, System.Type backendType, bool delayed = true ); 23 | void AddTargets( object[] targets, bool delayed = true ); 24 | 25 | // querying the graph 26 | object[] GetTargets(); 27 | IEnumerable GetEntities(); 28 | IEnumerable GetRelations(); 29 | 30 | #region direct graph manipulation 31 | 32 | // manipulate the graph directly 33 | void AddEntity( object entity, Vector2 position, bool delayed = true ); 34 | void RemoveEntity( object entity, bool delayed = true ); 35 | void ExpandEntity( object entity, bool delayed = true ); 36 | void FoldEntity( object entity, bool delayed = true ); 37 | 38 | // add relation that has yet to be connected to its target 39 | void InitRelation( object[] sourceEntity, bool delayed = true ); 40 | 41 | // get all relations involving the given entity 42 | object[] FindRelations( object entity ); 43 | 44 | // add relation 45 | void AddRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ); 46 | 47 | // remove relation 48 | void RemoveRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ); 49 | 50 | #endregion 51 | 52 | // set node selection 53 | void SelectEntityNodes( System.Predicate doSelect, bool delayed = true ); 54 | 55 | // get the skin 56 | RelationInspectorSkin GetSkin(); 57 | } 58 | 59 | internal interface RelationsInspectorAPI2 60 | { 61 | // draw a fresh view of the graph 62 | void Repaint(); 63 | 64 | // rebuild the graph from its current target objects 65 | void Rebuild(); 66 | 67 | // redo the layout on the current graph 68 | void Relayout(); 69 | 70 | // enforce backend selection 71 | void SetBackend( System.Type backendType, bool delayed = true ); 72 | 73 | // manipulate the graph through targets 74 | void ResetTargets( object[] targets, bool delayed = true ); 75 | void ResetTargets( object[] targets, System.Type backendType, bool delayed = true ); 76 | void AddTargets( object[] targets, bool delayed = true ); 77 | 78 | // querying the graph 79 | object[] GetTargets(); 80 | IEnumerable GetEntities(); 81 | IEnumerable GetRelations(); 82 | 83 | #region direct graph manipulation 84 | 85 | // manipulate the graph directly 86 | void AddEntity( object entity, Vector2 position, bool delayed = true ); 87 | void RemoveEntity( object entity, bool delayed = true ); 88 | void ExpandEntity( object entity, bool delayed = true ); 89 | void FoldEntity( object entity, bool delayed = true ); 90 | 91 | // add relation that has yet to be connected to its target 92 | void InitRelation( object[] sourceEntity, bool delayed = true ); 93 | 94 | // get all relations involving the given entity 95 | object[] FindRelations( object entity ); 96 | 97 | // add relation 98 | void AddRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ); 99 | 100 | // remove relation 101 | void RemoveRelation( object sourceEntity, object targetEntity, object tag, bool delayed = true ); 102 | 103 | #endregion 104 | 105 | // set node selection 106 | void SelectEntityNodes( System.Predicate doSelect, bool delayed = true ); 107 | 108 | // get the skin 109 | RelationInspectorSkin GetSkin(); 110 | } 111 | } 112 | -------------------------------------------------------------------------------- /RIDLLProject/RelationsInspectorLib.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 2012 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RelationsInspectorLib", "RelationsInspectorLib.csproj", "{8564B945-82F3-4C72-9661-3D6A6B311764}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /RIDLLProject/RelationsInspectorWindow.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using UnityEditor; 3 | using RelationsInspector.Extensions; 4 | 5 | // make internal classes accessible to unit tests 6 | #if DEBUG 7 | [assembly: System.Runtime.CompilerServices.InternalsVisibleTo( "Assembly-CSharp-Editor" )] 8 | [assembly: System.Runtime.CompilerServices.InternalsVisibleTo( "Assembly-CSharp" )] 9 | #endif 10 | 11 | 12 | namespace RelationsInspector 13 | { 14 | public delegate object GetAPI( int version ); 15 | 16 | public class RelationsInspectorWindow : EditorWindow 17 | { 18 | RIInternal internalAPI; 19 | APIv1Implementation api1impl; 20 | APIv2Implementation api2impl; 21 | 22 | [SerializeField] 23 | bool initialized; 24 | 25 | Rect workspaceRect; 26 | 27 | event System.Action OnUpdate; 28 | 29 | public RelationsInspectorAPI GetAPI1 { get { return api1impl; } } 30 | 31 | internal void ExecOnUpdate( System.Action action ) 32 | { 33 | OnUpdate += action; 34 | } 35 | 36 | public object GetAPI(int version) 37 | { 38 | switch ( version ) 39 | { 40 | case 1: 41 | default: 42 | return api1impl; 43 | } 44 | } 45 | 46 | void OnGUI() 47 | { 48 | if ( !initialized ) 49 | return; 50 | 51 | #if RIDEMO 52 | DemoRestriction.Run(); 53 | #endif// RIDEMO 54 | 55 | internalAPI.DrawToolbar(); 56 | 57 | // allow the user to draw their own controls and return the remaining rect 58 | var wsRect = internalAPI.DrawWorkspaceControls(); 59 | 60 | if ( Event.current.type == EventType.repaint ) 61 | workspaceRect = wsRect; 62 | 63 | // clip at the rect borders 64 | GUI.BeginGroup( workspaceRect, GUIStyle.none ); 65 | internalAPI.OnWorkspaceGUI( workspaceRect.ResetOrigin() ); 66 | GUI.EndGroup(); 67 | 68 | internalAPI.HandleEvent( Event.current, position ); 69 | } 70 | 71 | void OnSelectionChange() 72 | { 73 | internalAPI.OnSelectionChange(); 74 | } 75 | 76 | void OnDestroy() 77 | { 78 | internalAPI.OnDestroy(); 79 | #if RIDEMO 80 | DemoRestriction.OnDestroy(); 81 | #endif// RIDEMO 82 | AssetDatabase.SaveAssets(); 83 | } 84 | 85 | void InitWindow() 86 | { 87 | string dependencyError = ProjectSettings.CheckDependentFiles(); 88 | if ( !string.IsNullOrEmpty( dependencyError ) ) 89 | { 90 | ShowNotification( new GUIContent( dependencyError ) ); 91 | return; 92 | } 93 | 94 | wantsMouseMove = true; // for dragging edges 95 | 96 | internalAPI = new RIInternal( ExecOnUpdate, ShowNotification, this ); 97 | api1impl = new APIv1Implementation( internalAPI ); 98 | api2impl = new APIv2Implementation( internalAPI ); 99 | internalAPI.Init(); 100 | 101 | initialized = true; 102 | Repaint(); 103 | } 104 | 105 | void Update() 106 | { 107 | try 108 | { 109 | if ( OnUpdate != null ) 110 | { 111 | // reset OnUpdate BEFORE invoking it (!) so that actions can be added by the invoked code. 112 | System.Action stuffToExecute = OnUpdate; 113 | OnUpdate = null; 114 | stuffToExecute.Invoke(); 115 | Repaint(); 116 | } 117 | } 118 | catch ( System.Exception e ) 119 | { 120 | Debug.LogException( e ); 121 | } 122 | 123 | internalAPI.Update(); 124 | } 125 | 126 | void OnEnable() 127 | { 128 | InitWindow(); 129 | WelcomeWindow.SpawnOnFreshInstall(); 130 | #if RIDEMO 131 | DemoRestriction.OnEnable(); 132 | #endif// RIDEMO 133 | } 134 | } 135 | } 136 | 137 | -------------------------------------------------------------------------------- /RIDLLProject/Serialization/SaveLayoutAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector 4 | { 5 | [AttributeUsage( AttributeTargets.Class )] 6 | public class SaveLayoutAttribute : Attribute 7 | { 8 | public bool doSave; 9 | 10 | public SaveLayoutAttribute() 11 | { 12 | this.doSave = true; 13 | } 14 | 15 | public SaveLayoutAttribute( bool doSave ) 16 | { 17 | this.doSave = doSave; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /RIDLLProject/Serialization/TopologyStorage.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System; 5 | using UnityEditor; 6 | 7 | namespace RelationsInspector 8 | { 9 | public class TopologyStorage : ScriptableObject 10 | { 11 | public int[] nodes; 12 | public TopologyEdge[] edges; 13 | } 14 | 15 | [Serializable] 16 | public class TopologyEdge 17 | { 18 | public int sourceVertexId; 19 | public int targetVertexId; 20 | 21 | public TopologyEdge( int sourceId, int targetId ) 22 | { 23 | sourceVertexId = sourceId; 24 | targetVertexId = targetId; 25 | } 26 | } 27 | 28 | class TopologySerializer where T : class 29 | { 30 | public const string DefaultAssetPath = "Assets/graphTopology.asset"; 31 | 32 | public static void DumpTopology( Graph graph, string assetPath = DefaultAssetPath ) 33 | { 34 | var storage = CreateTopologyStorage( graph ); 35 | AssetDatabase.CreateAsset( storage, assetPath); 36 | AssetDatabase.SaveAssets(); 37 | } 38 | 39 | public static TopologyStorage CreateTopologyStorage( Graph graph ) 40 | { 41 | var storage = ScriptableObject.CreateInstance(); 42 | int id=0; 43 | var vertexId = graph.Vertices.ToArray().ToDictionary( v => v, v => id++ ); 44 | storage.nodes = vertexId.Values.ToArray(); 45 | 46 | var topologyEdges = graph.Vertices.SelectMany( v => GetTopologyEdges( graph, v, x => vertexId[x] ) ); 47 | storage.edges = topologyEdges.ToArray(); 48 | return storage; 49 | } 50 | 51 | static IEnumerable GetTopologyEdges( Graph graph, T vertex, Func vertexId ) 52 | { 53 | return graph.GetOutEdges( vertex ).Select( e => new TopologyEdge( vertexId( e.Source ), vertexId( e.Target ) ) ); 54 | } 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /RIDLLProject/Serialization/VertexPosition.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | [Serializable] 7 | public class VertexPosition 8 | { 9 | public int vertexId; 10 | public Vector2 vertexPosition; 11 | 12 | public VertexPosition( int id, Vector2 pos ) 13 | { 14 | this.vertexId = id; 15 | this.vertexPosition = pos; 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /RIDLLProject/Serialization/VertexPositionStorage.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections.Generic; 3 | 4 | namespace RelationsInspector 5 | { 6 | class VertexPositionStorage : ScriptableObject 7 | { 8 | public List vertexPositions; 9 | public Transform2d transform; 10 | public EntityWidgetType widgetType; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /RIDLLProject/Settings/RelationsInspectorSettings.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | class RelationsInspectorSettings : ScriptableObject 6 | { 7 | public bool cacheLayouts; 8 | public int maxGraphNodes; 9 | public TreeRootLocation treeRootLocation; 10 | public bool showMinimap; 11 | public MinimapLocation minimapLocation; 12 | [HideInInspector] 13 | public LayoutTweenParameters layoutTweenParameters; 14 | [HideInInspector] 15 | public GraphLayoutParameters graphLayoutParameters; 16 | public bool logToConsole; 17 | public bool invertZoom; 18 | public bool repaintEachFrame; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /RIDLLProject/Settings/Settings.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | internal class Settings 6 | { 7 | static RelationsInspectorSettings storage = Util.LoadOrCreate( ProjectSettings.SettingsPath, CreateDefaultStorage ); 8 | internal static RelationsInspectorSettings Instance 9 | { 10 | get { return storage; } 11 | } 12 | 13 | static RelationsInspectorSettings CreateDefaultStorage() 14 | { 15 | var storage = ScriptableObject.CreateInstance(); 16 | 17 | // initialize with default values 18 | storage.cacheLayouts = true; 19 | storage.maxGraphNodes = 50; 20 | storage.treeRootLocation = TreeRootLocation.Left; 21 | storage.showMinimap = true; 22 | storage.minimapLocation = MinimapLocation.TopLeft; 23 | storage.layoutTweenParameters = new LayoutTweenParameters(); 24 | storage.graphLayoutParameters = new GraphLayoutParameters(); 25 | storage.logToConsole = true; 26 | storage.invertZoom = false; 27 | return storage; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /RIDLLProject/Settings/SettingsInspector.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | using UnityEditor; 3 | using UnityEngine; 4 | 5 | namespace RelationsInspector 6 | { 7 | [CustomEditor( typeof( RelationsInspectorSettings ) )] 8 | class SettingsInspector : Editor 9 | { 10 | RelationsInspectorAPI api; 11 | RelationsInspectorSettings settings; 12 | bool foldLayoutTweenSettings; 13 | bool foldLayoutSettings; 14 | 15 | void OnEnable() 16 | { 17 | var riWindow = Resources.FindObjectsOfTypeAll().FirstOrDefault(); 18 | api = riWindow == null ? null : riWindow.GetAPI( 1 ) as RelationsInspectorAPI; 19 | settings = target as RelationsInspectorSettings; 20 | } 21 | 22 | public override void OnInspectorGUI() 23 | { 24 | GUILayout.Label( "Relations inspector settings", EditorStyles.boldLabel ); 25 | EditorGUILayout.Space(); 26 | 27 | settings.cacheLayouts = EditorGUILayout.Toggle( "Cache layouts", settings.cacheLayouts ); 28 | settings.maxGraphNodes = EditorGUILayout.IntField( "Max graph nodes", settings.maxGraphNodes ); 29 | 30 | EditorGUI.BeginChangeCheck(); 31 | settings.treeRootLocation = (TreeRootLocation) EditorGUILayout.EnumPopup( "Tree root location", settings.treeRootLocation ); 32 | if ( EditorGUI.EndChangeCheck() && api != null ) 33 | api.Relayout(); 34 | 35 | EditorGUI.BeginChangeCheck(); 36 | settings.showMinimap = EditorGUILayout.Toggle( "Show minimap", settings.showMinimap ); 37 | settings.minimapLocation = (MinimapLocation) EditorGUILayout.EnumPopup( "Minimap location", settings.minimapLocation ); 38 | if ( EditorGUI.EndChangeCheck() && api != null ) 39 | api.Repaint(); 40 | 41 | settings.logToConsole = EditorGUILayout.Toggle( "Log to console", settings.logToConsole ); 42 | settings.invertZoom = EditorGUILayout.Toggle( "Invert zoom", settings.invertZoom ); 43 | #if DEBUG 44 | settings.repaintEachFrame = EditorGUILayout.Toggle( "Repaint each frame", settings.repaintEachFrame ); 45 | ShowGraphLayoutParams( settings.graphLayoutParameters ); 46 | ShowLayoutTweenParams( settings.layoutTweenParameters ); 47 | #endif 48 | if ( GUI.changed ) 49 | EditorUtility.SetDirty( settings ); 50 | } 51 | 52 | void ShowGraphLayoutParams( GraphLayoutParameters parameters ) 53 | { 54 | EditorGUILayout.Space(); 55 | foldLayoutSettings = EditorGUILayout.Foldout( foldLayoutSettings, "Graph layout settings" ); 56 | if ( foldLayoutSettings ) 57 | { 58 | GUILayout.BeginHorizontal(); 59 | GUILayout.Space( 10 ); 60 | GUILayout.BeginVertical(); 61 | 62 | parameters.posInitRange = EditorGUILayout.FloatField( "Init positioning range", parameters.posInitRange ); 63 | parameters.idealDistance = EditorGUILayout.FloatField( "Ideal vertex spacing", parameters.idealDistance ); 64 | parameters.initalMaxMove = EditorGUILayout.FloatField( "Inital max move", parameters.initalMaxMove ); 65 | parameters.numIterations = EditorGUILayout.IntField( "Number of iterations", parameters.numIterations ); 66 | parameters.gravityStrength = EditorGUILayout.FloatField( "Gravity strength", parameters.gravityStrength ); 67 | 68 | GUILayout.EndVertical(); 69 | GUILayout.EndHorizontal(); 70 | } 71 | } 72 | 73 | void ShowLayoutTweenParams( LayoutTweenParameters lParams ) 74 | { 75 | EditorGUILayout.Space(); 76 | foldLayoutTweenSettings = EditorGUILayout.Foldout( foldLayoutTweenSettings, "Layout tween settings" ); 77 | if ( foldLayoutTweenSettings ) 78 | { 79 | GUILayout.BeginHorizontal(); 80 | GUILayout.Space( 10 ); 81 | GUILayout.BeginVertical(); 82 | 83 | lParams.maxFrameDuration = EditorGUILayout.FloatField( "Frame duration", lParams.maxFrameDuration ); 84 | 85 | EditorGUILayout.Space(); 86 | GUILayout.Label( "Position tweens", EditorStyles.boldLabel ); 87 | lParams.vertexPosTweenDuration = EditorGUILayout.FloatField( "Duration", lParams.vertexPosTweenDuration ); 88 | lParams.vertexPosTweenUpdateInterval = EditorGUILayout.FloatField( "Update interval", lParams.vertexPosTweenUpdateInterval ); 89 | 90 | GUILayout.EndVertical(); 91 | GUILayout.EndHorizontal(); 92 | } 93 | } 94 | } 95 | } 96 | -------------------------------------------------------------------------------- /RIDLLProject/Settings/SettingsMenu.cs: -------------------------------------------------------------------------------- 1 | using UnityEditor; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | class SettingsMenu 7 | { 8 | internal static void Create() 9 | { 10 | var menu = new GenericMenu(); 11 | menu.AddItem( new GUIContent( "Settings" ), false, () => Selection.activeObject = Settings.Instance ); 12 | menu.AddItem( new GUIContent( "Skin" ), false, () => Selection.activeObject = SkinManager.GetSkin() ); 13 | menu.AddItem( new GUIContent( "Info + Addons" ), false, () => WelcomeWindow.SpawnWindow() ); 14 | #if RIDEMO 15 | menu.AddItem( new GUIContent( "Buy RI" ), false, () => UnityEditorInternal.AssetStore.Open( ProjectSettings.StoreDemoURL ) ); 16 | #endif 17 | menu.ShowAsContext(); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /RIDLLProject/Style/EntityWidgetStyle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | [Serializable] 7 | public class EntityWidgetStyle 8 | { 9 | public Color backgroundColor; 10 | public Color highlightColor; 11 | public Color unexploredColor; 12 | public Color shadowColor; 13 | public int highlightStrength; 14 | public GUIStyle contentStyle; 15 | public float widgetRadius; // for circle widget only 16 | public Color targetBackgroundColor; 17 | public Texture2D discImage; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /RIDLLProject/Style/MinimapStyle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | [Serializable] 7 | public class MinimapStyle 8 | { 9 | public Color backgroundColor; 10 | public Color vertexMarkerColor; 11 | public Color viewRectColor; 12 | public int size; 13 | public int spacing; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /RIDLLProject/Style/RelationDrawerStyle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | [Serializable] 7 | public class RelationDrawerStyle 8 | { 9 | public Color regularEdgeColor; 10 | public int regularEdgeWidth; 11 | public Color highlightEdgeColor; 12 | public int highlightEdgeWidth; 13 | public Vector2 markerSize; 14 | public Texture2D markerImage; 15 | public float edgeGapSize; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /RIDLLProject/Style/Skin.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | public class RelationInspectorSkin : ScriptableObject 6 | { 7 | public MinimapStyle minimap; 8 | public EntityWidgetStyle entityWidget; 9 | public RelationDrawerStyle relationDrawer; 10 | public Color windowColor; 11 | public Texture2D settingsIcon; 12 | public Texture2D prevIcon; 13 | public Texture2D nextIcon; 14 | public GUIStyle tooltipStyle; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Extensions/LinqExtensions.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Linq; 3 | 4 | namespace RelationsInspector.Extensions 5 | { 6 | public static class LinqExtensions 7 | { 8 | public static HashSet ToHashSet( this IEnumerable sequence ) 9 | { 10 | if ( sequence == null ) 11 | throw new System.ArgumentException( "sequence" ); 12 | 13 | return new HashSet( sequence ); 14 | } 15 | 16 | public static void Enqueue( this Queue queue, IEnumerable items ) 17 | { 18 | if ( queue == null ) 19 | throw new System.ArgumentException( "queue" ); 20 | if ( items == null ) 21 | throw new System.ArgumentException( "items" ); 22 | 23 | foreach ( var item in items ) 24 | queue.Enqueue( item ); 25 | } 26 | 27 | public static string ToDelimitedString( this IEnumerable sequence ) 28 | { 29 | if ( sequence == null ) 30 | return "null"; 31 | 32 | var sb = new System.Text.StringBuilder(); 33 | 34 | sb.Append( "(" ); 35 | //sequence.Aggregate(sb, (builder, item) => { builder.Append(", " + item.ToString()); return builder; } ); 36 | 37 | bool firstvalue = true; 38 | foreach ( var value in sequence ) 39 | { 40 | if ( !firstvalue ) 41 | sb.Append( ", " ); 42 | 43 | firstvalue = false; 44 | sb.Append( value ); 45 | } 46 | sb.Append( ")" ); 47 | 48 | return sb.ToString(); 49 | } 50 | 51 | public static void UnionWith( this Dictionary dict, Dictionary other ) 52 | { 53 | if ( dict == null ) 54 | throw new System.ArgumentNullException( "dict" ); 55 | 56 | if ( other == null ) 57 | throw new System.ArgumentNullException( "other" ); 58 | 59 | foreach ( var pair in other ) 60 | { 61 | if ( dict.ContainsKey( pair.Key ) ) 62 | throw new System.ArgumentException( "dict keys are not disjunct" ); 63 | 64 | dict[ pair.Key ] = pair.Value; 65 | } 66 | } 67 | 68 | public static void RemoveWhere( this ICollection collection, System.Func condition ) 69 | { 70 | List toRemove = collection.Where( condition ).ToList(); 71 | 72 | foreach ( T obj in toRemove ) 73 | { 74 | collection.Remove( obj ); 75 | } 76 | } 77 | 78 | // avoid naming conflict with linq's IEnumerable.Reverse (which is slower) 79 | public static IEnumerable FastReverse( this LinkedList list ) 80 | { 81 | var el = list.Last; 82 | while ( el != null ) 83 | { 84 | yield return el.Value; 85 | el = el.Previous; 86 | } 87 | } 88 | } 89 | } 90 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Extensions/RectExtensions.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector.Extensions 4 | { 5 | public static class RectExtensions 6 | { 7 | public static Vector2 GetOrigin( this Rect rect ) 8 | { 9 | return new Vector2( rect.x, rect.y ); 10 | } 11 | 12 | public static Rect ResetOrigin( this Rect rect ) 13 | { 14 | return new Rect( 0, 0, rect.width, rect.height ); 15 | } 16 | 17 | public static Vector2 GetExtents( this Rect rect ) 18 | { 19 | return new Vector2( rect.width, rect.height ); 20 | } 21 | 22 | public static Rect ClampExtents( this Rect rect, float minWidth, float minHeight, float maxWidth, float maxHeight ) 23 | { 24 | float width = Mathf.Clamp( rect.width, minWidth, maxWidth ); 25 | float height = Mathf.Clamp( rect.height, minHeight, maxHeight ); 26 | return Util.CenterRect( rect.center, width, height ); 27 | } 28 | 29 | public static Rect Scale( this Rect rect, float factor ) 30 | { 31 | return Util.CenterRect( rect.center, rect.GetExtents() * factor ); 32 | } 33 | 34 | public static Rect Scale( this Rect rect, Vector2 scale ) 35 | { 36 | return Util.CenterRect( rect.center, rect.width * scale.x, rect.height * scale.y ); 37 | } 38 | 39 | public static Rect Move( this Rect rect, Vector2 shift ) 40 | { 41 | return new Rect 42 | ( 43 | rect.xMin + shift.x, 44 | rect.yMin + shift.y, 45 | rect.width, 46 | rect.height 47 | ); 48 | } 49 | 50 | public static Vector2[] Vertices( this Rect rect ) 51 | { 52 | return new[] 53 | { 54 | new Vector2(rect.xMin, rect.yMin), 55 | new Vector2(rect.xMin, rect.yMax), 56 | new Vector2(rect.xMax, rect.yMax), 57 | new Vector2(rect.xMax, rect.yMin) 58 | }; 59 | } 60 | 61 | public static Rect Intersection( this Rect rect, Rect other ) 62 | { 63 | float xMin = Mathf.Max( rect.xMin, other.xMin ); 64 | float xMax = Mathf.Min( rect.xMax, other.xMax ); 65 | float yMin = Mathf.Max( rect.yMin, other.yMin ); 66 | float yMax = Mathf.Min( rect.yMax, other.yMax ); 67 | 68 | if ( xMin >= xMax || yMin >= yMax ) 69 | return Util.rectZero; 70 | 71 | return Rect.MinMaxRect( xMin, yMin, xMax, yMax ); 72 | } 73 | 74 | public static bool Intersects( this Rect a, Rect b ) 75 | { 76 | return ( a.xMin <= b.xMax && 77 | b.xMin <= a.xMax && 78 | a.yMin <= b.yMax && 79 | b.yMin <= a.yMax ); 80 | } 81 | 82 | public static Rect AddBorder( this Rect rect, float border ) 83 | { 84 | return new Rect 85 | ( 86 | rect.xMin - border, 87 | rect.yMin - border, 88 | rect.width + 2 * border, 89 | rect.height + 2 * border 90 | ); 91 | } 92 | 93 | public static Rect AddBorder( this Rect rect, float horizontal, float vertical ) 94 | { 95 | return new Rect 96 | ( 97 | rect.xMin - horizontal, 98 | rect.yMin - vertical, 99 | rect.width + 2 * horizontal, 100 | rect.height + 2 * vertical 101 | ); 102 | } 103 | 104 | public static Rect AddBorder( this Rect rect, float left, float right, float top, float bottom ) 105 | { 106 | return new Rect 107 | ( 108 | rect.xMin - left, 109 | rect.yMin - top, 110 | rect.width + left + right, 111 | rect.height + top + bottom 112 | ); 113 | } 114 | } 115 | } 116 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Extensions/StringExtensions.cs: -------------------------------------------------------------------------------- 1 | namespace RelationsInspector.Extensions 2 | { 3 | public static class StringExtensions 4 | { 5 | public static string RemovePrefix( this string str, string prefix ) 6 | { 7 | if ( str == null ) 8 | throw new System.ArgumentException( "str" ); 9 | 10 | if ( prefix == null ) 11 | throw new System.ArgumentException( "prefix" ); 12 | 13 | if ( !str.StartsWith( prefix ) ) 14 | throw new System.ArgumentException( "str is " + str + ". expected " + prefix ); 15 | 16 | return str.Substring( prefix.Length ); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Extensions/TypeExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Linq; 3 | 4 | namespace RelationsInspector.Extensions 5 | { 6 | public static class TypeExtensions 7 | { 8 | public static bool IsOpen( this Type type ) 9 | { 10 | if ( type == null ) 11 | throw new ArgumentException( "type" ); 12 | 13 | return type.GetGenericArguments().Any( arg => arg.IsGenericParameter ); 14 | } 15 | 16 | public static bool Implements( this Type candidateType, Type interfaceType ) 17 | { 18 | return ( 19 | interfaceType.IsInterface && 20 | !candidateType.IsInterface && 21 | !candidateType.IsAbstract && 22 | interfaceType.IsAssignableFrom( candidateType ) 23 | ); 24 | } 25 | 26 | public static bool TakesCtorParam( this Type candidateType, Type paramType ) 27 | { 28 | // needs to have a ctor whose single param's type can be assigned to from paramType 29 | foreach ( var ctor in candidateType.GetConstructors() ) 30 | { 31 | var parameters = ctor.GetParameters(); 32 | if ( parameters.Length != 1 ) 33 | continue; 34 | 35 | if ( !parameters[ 0 ].ParameterType.IsAssignableFrom( paramType ) ) 36 | continue; 37 | 38 | return true; 39 | } 40 | return false; 41 | } 42 | 43 | public static T[] GetCustomAttributes( this Type type, bool inherit ) where T : Attribute 44 | { 45 | return (T[]) type.GetCustomAttributes( typeof( T ), inherit ); 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Extensions/Vector2Extensions.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector.Extensions 4 | { 5 | public static class Vector2Extensions 6 | { 7 | public static Vector2 Clamp( this Vector2 source, Rect bounds ) 8 | { 9 | return new Vector2 10 | ( 11 | Mathf.Clamp( source.x, bounds.xMin, bounds.xMax ), 12 | Mathf.Clamp( source.y, bounds.yMin, bounds.yMax ) 13 | ); 14 | } 15 | 16 | public static Vector2 Clamp( this Vector2 source, Vector2 min, Vector2 max ) 17 | { 18 | return new Vector2 19 | ( 20 | Mathf.Clamp( source.x, min.x, max.x ), 21 | Mathf.Clamp( source.y, min.y, max.y ) 22 | ); 23 | } 24 | 25 | public static Vector2 RotateAround( this Vector2 source, Vector2 pivot, float angle ) 26 | { 27 | source -= pivot; 28 | float radius = source.magnitude; 29 | angle += Util.GetAngle( source ); 30 | source = new Vector2( Mathf.Cos( angle ) * radius, Mathf.Sin( angle ) * radius ); 31 | 32 | return source + pivot; 33 | } 34 | 35 | // returns the left normal vector 36 | public static Vector2 Normal( this Vector2 source ) 37 | { 38 | return new Vector2( -source.y, source.x ); 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/GLMaterials.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | public class GLMaterials 6 | { 7 | public static Material defaultMat; 8 | 9 | static GLMaterials() 10 | { 11 | // http://wiki.unity3d.com/index.php/GLDraw 12 | defaultMat = new Material( "Shader \"Lines/Colored Blended\" {" + 13 | "SubShader { Pass { " + 14 | " Blend SrcAlpha OneMinusSrcAlpha " + 15 | " ZWrite Off Cull Off Fog { Mode Off } " + 16 | " BindChannels {" + 17 | " Bind \"vertex\", vertex Bind \"color\", color }" + 18 | "} } }" ); 19 | 20 | defaultMat.hideFlags = HideFlags.HideAndDontSave; 21 | defaultMat.shader.hideFlags = HideFlags.HideAndDontSave; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/GUIUtil.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Linq; 3 | using UnityEngine; 4 | using UnityEditor; 5 | 6 | namespace RelationsInspector 7 | { 8 | class GUIUtil 9 | { 10 | public static string GetPrefsKey( string localKey ) 11 | { 12 | // create a name that should be a unique EditorPrefs key 13 | // by prefixing the project name (namespacing) 14 | return System.IO.Path.Combine( ProjectSettings.EditorPrefsProjectPrefix, localKey ); 15 | } 16 | 17 | public static void SetPrefsInt( string localKey, int value ) 18 | { 19 | EditorPrefs.SetInt( GetPrefsKey( localKey ), value ); 20 | } 21 | 22 | public static int GetPrefsInt( string localKey ) 23 | { 24 | return EditorPrefs.GetInt( GetPrefsKey( localKey ) ); 25 | } 26 | 27 | public static int GetPrefsInt( string localKey, int defaultValue ) 28 | { 29 | string prefsKey = GetPrefsKey( localKey ); 30 | if ( !EditorPrefs.HasKey( prefsKey ) ) 31 | return defaultValue; 32 | 33 | return EditorPrefs.GetInt( prefsKey ); 34 | } 35 | 36 | public static void SetPrefsString( string localKey, string value ) 37 | { 38 | EditorPrefs.SetString( GetPrefsKey( localKey ), value ); 39 | } 40 | 41 | public static string GetPrefsString( string localKey ) 42 | { 43 | return EditorPrefs.GetString( GetPrefsKey( localKey ) ); 44 | } 45 | 46 | public static string GetPrefsString( string localKey, string defaultValue ) 47 | { 48 | string prefsKey = GetPrefsKey( localKey ); 49 | if ( !EditorPrefs.HasKey( prefsKey ) ) 50 | return defaultValue; 51 | 52 | return EditorPrefs.GetString( prefsKey ); 53 | } 54 | 55 | public static void SetPrefsBackendType( string localKey, Type value ) 56 | { 57 | SetPrefsString( localKey, value.ToString() ); 58 | } 59 | 60 | public static Type GetPrefsBackendType( string localKey ) 61 | { 62 | string typeName = GetPrefsString( localKey ); 63 | if ( string.IsNullOrEmpty( typeName ) ) 64 | return null; 65 | 66 | return BackendTypeUtil.backendTypes.SingleOrDefault( t => t.ToString() == typeName ); //.Split( '`' )[ 0 ] 67 | } 68 | 69 | /// Creates a toolbar that is filled from an Enum. (CC-BY-SA, from http://wiki.unity3d.com/index.php?title=EditorGUIExtension) 70 | public static Enum EnumToolbar( string prefixLabel, Enum selected, GUIStyle style, params GUILayoutOption[] options ) 71 | { 72 | Func getContent = ( item ) => new GUIContent( Enum.GetName( item.GetType(), item ) ); 73 | return EnumToolbar( prefixLabel, selected, getContent, style, options ); 74 | } 75 | 76 | /// Creates a toolbar that is filled from an Enum. (CC-BY-SA, from http://wiki.unity3d.com/index.php?title=EditorGUIExtension) 77 | public static Enum EnumToolbar( string prefixLabel, Enum selected, Func getContent, GUIStyle style, params GUILayoutOption[] options ) 78 | { 79 | var values = Enum.GetValues( selected.GetType() ); 80 | var contents = values.OfType().Select( val => getContent( val ) ).ToArray(); 81 | 82 | int selected_index = 0; 83 | while ( selected_index < values.Length ) 84 | { 85 | if ( selected.ToString() == values.GetValue( selected_index ).ToString() ) 86 | break; 87 | selected_index++; 88 | } 89 | 90 | GUILayout.BeginHorizontal(); 91 | if ( !string.IsNullOrEmpty( prefixLabel ) ) 92 | { 93 | GUILayout.Label( prefixLabel ); 94 | GUILayout.Space( 10 ); 95 | } 96 | 97 | selected_index = GUILayout.Toolbar( selected_index, contents, style, options ); 98 | GUILayout.FlexibleSpace(); 99 | GUILayout.EndHorizontal(); 100 | 101 | return (Enum) values.GetValue( selected_index ); 102 | } 103 | 104 | public static Rect GUIToScreenRect( Rect rect ) 105 | { 106 | Vector2 origin = GUIUtility.GUIToScreenPoint( new Vector2( rect.x, rect.y ) ); 107 | rect.x = origin.x; 108 | rect.y = origin.y; 109 | return rect; 110 | } 111 | } 112 | } 113 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/RNG.cs: -------------------------------------------------------------------------------- 1 | namespace RelationsInspector 2 | { 3 | public class RNG 4 | { 5 | System.Random rng; 6 | 7 | public RNG( int seed ) 8 | { 9 | rng = new System.Random( seed ); 10 | } 11 | 12 | public float Range( float min = 0f, float max = 1f ) 13 | { 14 | float range = max - min; 15 | float rndValue = (float) rng.NextDouble(); 16 | return min + range * rndValue; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Transform2d.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using RelationsInspector.Extensions; 3 | 4 | namespace RelationsInspector 5 | { 6 | [System.Serializable] 7 | public class Transform2d 8 | { 9 | public Vector2 translation; 10 | public Vector2 scale; 11 | public float rotation; 12 | 13 | public Transform2d() : this( Vector2.zero, Vector2.one, 0 ) { } 14 | 15 | public Transform2d( Vector2 translation, Vector2 scale, float rotation ) 16 | { 17 | this.translation = translation; 18 | this.scale = scale; 19 | this.rotation = rotation; 20 | } 21 | 22 | public Transform2d( Transform2d other ) 23 | { 24 | this.translation = other.translation; 25 | this.scale = other.scale; 26 | this.rotation = other.rotation; 27 | } 28 | 29 | public static void Copy( Transform2d from, Transform2d to ) 30 | { 31 | to.translation = from.translation; 32 | to.scale = from.scale; 33 | to.rotation = from.rotation; 34 | } 35 | 36 | public Vector2 Apply( Vector2 source ) 37 | { 38 | return new Vector2( source.x * scale.x + translation.x, source.y * scale.y + translation.y ); 39 | } 40 | 41 | public Rect Apply( Rect source ) 42 | { 43 | var newCenter = Apply( source.center ); 44 | return Util.CenterRect( newCenter, ApplyScale( source.GetExtents() ) ); 45 | } 46 | 47 | public Vector2 ApplyScale( Vector2 source ) 48 | { 49 | return new Vector2( source.x * scale.x, source.y * scale.y ); 50 | } 51 | 52 | public Rect ApplyScale( Rect r ) 53 | { 54 | Vector2 center = r.center; 55 | Vector2 newCenter = new Vector2( center.x * scale.x, center.y * scale.y ); 56 | return Util.CenterRect( newCenter, r.width * scale.x, r.height * scale.y ); 57 | } 58 | 59 | public Vector2 Revert( Vector2 source ) 60 | { 61 | float x = scale.x != 0 ? ( source.x - translation.x ) / scale.x : 0; 62 | float y = scale.y != 0 ? ( source.y - translation.y ) / scale.y : 0; 63 | return new Vector2( x, y ); 64 | } 65 | 66 | public Rect Revert( Rect source ) 67 | { 68 | Vector2 center = Revert( source.center ); 69 | Vector2 extents = RevertScale( source.GetExtents() ); 70 | return Util.CenterRect( center, extents ); 71 | } 72 | 73 | public Vector2 RevertScale( Vector2 source ) 74 | { 75 | float x = scale.x != 0 ? source.x / scale.x : 0; 76 | float y = scale.y != 0 ? source.y / scale.y : 0; 77 | return new Vector2( x, y ); 78 | } 79 | 80 | /* 81 | private Vector2 ApplyRotation(Vector2 source, Vector2 pivot) 82 | { 83 | source -= pivot; 84 | 85 | float angle = Util.GetAngle(source) + rotation; 86 | float radius = source.magnitude; 87 | source = new Vector2(Mathf.Cos(angle) * radius, Mathf.Sin(angle) * radius); 88 | 89 | return source + pivot; 90 | } 91 | */ 92 | 93 | public override string ToString() 94 | { 95 | return string.Format( "T {0} R {1} S {2}", translation, rotation, scale ); 96 | } 97 | } 98 | } 99 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Tweening/Easing.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector.Tweening 5 | { 6 | public enum TwoValueEasing 7 | { 8 | Linear, 9 | QuadraticIn, 10 | QuadraticOut, 11 | QuadraticInOut, 12 | CubicIn, 13 | CubicOut, 14 | CubicInOut, 15 | SineIn, 16 | SineOut, 17 | SineInOut 18 | } 19 | 20 | public enum ThreeValueEasing 21 | { 22 | BezierQuadratic 23 | } 24 | 25 | class Easing 26 | { 27 | public static readonly Dictionary twoValueEasings = new Dictionary 28 | { 29 | {TwoValueEasing.Linear, Linear }, 30 | {TwoValueEasing.QuadraticIn, QuadraticIn }, 31 | {TwoValueEasing.QuadraticOut, QuadraticOut }, 32 | {TwoValueEasing.QuadraticInOut, QuadraticInOut }, 33 | {TwoValueEasing.CubicIn, CubicIn }, 34 | {TwoValueEasing.CubicOut, CubicOut }, 35 | {TwoValueEasing.CubicInOut, CubicInOut }, 36 | {TwoValueEasing.SineIn, SineIn }, 37 | {TwoValueEasing.SineOut, SineOut }, 38 | {TwoValueEasing.SineInOut, SineInOut }, 39 | }; 40 | 41 | public static readonly Dictionary threeValueEasings = new Dictionary 42 | { 43 | {ThreeValueEasing.BezierQuadratic, BezierQuadratic} 44 | }; 45 | 46 | // returns value at time t on the curve defined by a,b,c (with t in [0,1]) 47 | public static float BezierQuadratic( float a, float b, float c, float t ) 48 | { 49 | float r = 1 - t; // remaining time 50 | return r * r * a + 2 * r * t * b + t * t * c; 51 | } 52 | 53 | // linear interpolation between a and b (with t in [0,1]) 54 | public static float Linear( float t ) 55 | { 56 | return t; 57 | } 58 | 59 | public static float QuadraticIn(float t) 60 | { 61 | return t*t; 62 | } 63 | 64 | public static float QuadraticOut(float t) 65 | { 66 | return t*(2-t); 67 | } 68 | 69 | public static float QuadraticInOut(float t) 70 | { 71 | if ((t *= 2) < 1) 72 | return 0.5f * t * t; 73 | 74 | return - 0.5f * (--t * (t - 2) - 1); 75 | } 76 | 77 | public static float CubicIn(float t) 78 | { 79 | return t*t*t; 80 | } 81 | 82 | public static float CubicOut(float t) 83 | { 84 | return --t * t * t + 1; ; 85 | } 86 | 87 | public static float CubicInOut(float k) 88 | { 89 | if ((k *= 2) < 1) 90 | { 91 | return 0.5f * k * k * k; 92 | } 93 | 94 | return 0.5f * ((k -= 2) * k * k + 2); 95 | } 96 | 97 | 98 | public static float SineIn(float k) 99 | { 100 | return 1 - Mathf.Cos(k * Mathf.PI / 2); 101 | } 102 | 103 | public static float SineOut(float k) 104 | { 105 | return Mathf.Sin(k * Mathf.PI / 2); 106 | } 107 | 108 | public static float SineInOut(float k) 109 | { 110 | return 0.5f * (1 - Mathf.Cos(Mathf.PI * k)); 111 | } 112 | 113 | } 114 | } 115 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Tweening/Tween.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace RelationsInspector.Tweening 4 | { 5 | public interface ITween 6 | { 7 | void Update( float time ); 8 | bool IsExpired( float time ); 9 | void Finish(); 10 | } 11 | 12 | public class Tween : ITween 13 | { 14 | Action setValue; 15 | EvalAtIntervalTime evalAtTime; 16 | float endTime; 17 | 18 | public Tween( Action setValue, float duration, EvalAtNormTime evalAtNormTime ) 19 | { 20 | this.setValue = setValue; 21 | 22 | float startTime = (float) UnityEditor.EditorApplication.timeSinceStartup; 23 | this.endTime = startTime + duration; 24 | 25 | evalAtTime = time => evalAtNormTime( Clamp01( ( time - startTime ) / duration ) ); 26 | } 27 | 28 | static float Clamp01(float f) 29 | { 30 | if (f < 0) return 0; 31 | if (f > 1) return 1; 32 | return f; 33 | } 34 | 35 | public void Update( float time ) 36 | { 37 | setValue( evalAtTime( time ) ); 38 | } 39 | 40 | public bool IsExpired( float time ) 41 | { 42 | return time > endTime; 43 | } 44 | 45 | public void Finish() 46 | { 47 | Update( endTime ); 48 | } 49 | 50 | public T GetFinalValue() 51 | { 52 | return evalAtTime(float.MaxValue); 53 | } 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Tweening/TweenCollection.cs: -------------------------------------------------------------------------------- 1 | using UnityEditor; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace RelationsInspector.Tweening 6 | { 7 | public class TweenCollection 8 | { 9 | HashSet tweens = new HashSet(); 10 | Dictionary tweenOwners = new Dictionary(); 11 | 12 | public bool HasChanges { get; private set; } // true if the last update changed any tweened values 13 | 14 | public void Update() 15 | { 16 | Update( (float) EditorApplication.timeSinceStartup ); 17 | } 18 | 19 | public void Update(float time) 20 | { 21 | // if the collection contains any tweens, there will be value changes 22 | // even the expired tweens still change values (setting the final ones) 23 | HasChanges = tweens.Any(); 24 | 25 | // find the expired 26 | var expired = tweens.Where( t => t.IsExpired( time ) ); 27 | 28 | // finalize and remove them 29 | if (expired.Any()) 30 | { 31 | foreach (var exp in expired.ToArray()) 32 | { 33 | exp.Finish(); 34 | tweens.Remove(exp); 35 | } 36 | } 37 | 38 | // update the remaining 39 | foreach (var tween in tweens) 40 | tween.Update(time); 41 | } 42 | 43 | public void Clear() 44 | { 45 | tweens.Clear(); 46 | } 47 | 48 | public void Add( ITween tween ) 49 | { 50 | tweens.Add( tween ); 51 | } 52 | 53 | public void Replace(object owner, ITween tween) 54 | { 55 | if (tweenOwners.ContainsKey(owner)) 56 | tweens.Remove(tweenOwners[owner]); 57 | 58 | tweens.Add(tween); 59 | tweenOwners[owner] = tween; 60 | } 61 | 62 | public bool HasTween(object owner) 63 | { 64 | return tweenOwners.ContainsKey(owner); 65 | } 66 | 67 | public T GetFinalValue(object owner) 68 | { 69 | ITween tween; 70 | if (!tweenOwners.TryGetValue(owner, out tween)) 71 | return default(T); 72 | 73 | return (tween as Tween).GetFinalValue(); 74 | } 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Tweening/TweenUtil.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector.Tweening 4 | { 5 | public delegate float Easing2( float time ); 6 | public delegate float Easing3( float a, float b, float c, float time ); 7 | public delegate T EvalAtNormTime( float time ); // expects normalized time (0..1) 8 | public delegate T EvalAtIntervalTime( float time ); 9 | 10 | public static class TweenUtil 11 | { 12 | 13 | public static EvalAtNormTime Float2( float startValue, float endValue, TwoValueEasing mode ) 14 | { 15 | float diff = endValue - startValue; 16 | return time => startValue + diff * Easing.twoValueEasings[mode]( time ); 17 | } 18 | 19 | public static EvalAtNormTime Float3( float startValue, float controlValue, float endValue, ThreeValueEasing mode ) 20 | { 21 | return time => Easing.threeValueEasings[mode](startValue, controlValue, endValue, time); 22 | } 23 | 24 | public static EvalAtNormTime Vector2_2( Vector2 startValue, Vector2 endValue, TwoValueEasing mode ) 25 | { 26 | var xEval = Float2( startValue.x, endValue.x, mode ); 27 | var yEval = Float2( startValue.y, endValue.y, mode ); 28 | return time => new Vector2( xEval( time ), yEval( time ) ); 29 | } 30 | 31 | public static EvalAtNormTime Vector2_3( Vector2 startValue, Vector2 controlValue, Vector2 endValue, ThreeValueEasing mode ) 32 | { 33 | var xEval = Float3( startValue.x, controlValue.x, endValue.x, mode ); 34 | var yEval = Float3( startValue.y, controlValue.y, endValue.y, mode ); 35 | return time => new Vector2( xEval( time ), yEval( time ) ); 36 | } 37 | 38 | public static EvalAtNormTime Transform2( Transform2d startValue, Transform2d endValue, TwoValueEasing mode ) 39 | { 40 | var translateEval = Vector2_2( startValue.translation, endValue.translation, mode ); 41 | var scaleEval = Vector2_2( startValue.scale, endValue.scale, mode ); 42 | var rotateEval = Float2( startValue.rotation, endValue.rotation, mode ); 43 | return time => new Transform2d( translateEval( time ), scaleEval( time ), rotateEval( time ) ); 44 | } 45 | 46 | public static EvalAtNormTime GetCombinedEasing(object owner, TweenCollection collection, Vector2 startValue, Vector2 endValue) 47 | { 48 | if(!collection.HasTween(owner)) 49 | return Vector2_2(startValue, endValue, TwoValueEasing.Linear); 50 | 51 | Vector2 midValue = collection.GetFinalValue(owner); 52 | return Vector2_3(startValue, midValue, endValue, ThreeValueEasing.BezierQuadratic); 53 | } 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /RIDLLProject/Tools/Tweening/Tweener.cs: -------------------------------------------------------------------------------- 1 | using UnityEditor; 2 | 3 | namespace RelationsInspector.Tweening 4 | { 5 | public static class Tweener 6 | { 7 | public static TweenCollection gen = new TweenCollection(); // generic collection 8 | 9 | static Tweener() 10 | { 11 | EditorApplication.update += Update; 12 | } 13 | 14 | static void Update() 15 | { 16 | gen.Update((float)EditorApplication.timeSinceStartup); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /RIDLLProject/View/IGraphView.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections.Generic; 3 | 4 | namespace RelationsInspector 5 | { 6 | internal interface IGraphView where T : class 7 | { 8 | void Draw(); 9 | void OnToolbarGUI(); 10 | void HandleEvent( Event ev ); 11 | 12 | Vector2 GetGraphPosition( Vector2 windowPos ); 13 | void CreateEdge( IEnumerable sourceEntities ); 14 | 15 | void OnRemovedEntity( T entity ); 16 | void OnRemovedRelation( Relation relation ); 17 | 18 | void SelectEntityNodes( System.Predicate doSelect ); 19 | void FitViewRectToGraph( bool immediately ); 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /RIDLLProject/View/IRelationDrawer.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | public interface IRelationDrawer where T : class 7 | { 8 | Dictionary, Rect> DrawRelation( IEnumerable> toEdges, IEnumerable> fromEdges, EdgePlacement placement, bool isSelfEdge, bool highLight, bool includeMarker, RelationDrawerStyle style, System.Func GetMarkerColor ); 9 | 10 | void DrawPseudoRelation( EdgePlacement placement, bool isSelfEdge, RelationDrawerStyle relationDrawerStyle ); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /RIDLLProject/View/IViewParent.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace RelationsInspector 4 | { 5 | internal interface IViewParent where T : class 6 | { 7 | void RepaintView(); 8 | Rect GetViewRect(); 9 | 10 | void MoveEntity( T entity, Vector2 delta ); 11 | 12 | bool IsSeed( T entity ); // is entity derived from a inspector target object? 13 | IGraphBackendInternal GetBackend(); 14 | RelationsInspectorAPI GetAPI(); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /RIDLLProject/View/Minimap.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using UnityEditor; 3 | using System.Linq; 4 | using RelationsInspector.Extensions; 5 | using System.Collections.Generic; 6 | 7 | namespace RelationsInspector 8 | { 9 | public enum MinimapLocation { TopLeft, TopRight, BottomLeft, BottomRight }; 10 | 11 | internal class Minimap 12 | { 13 | internal static Rect GetRect( MinimapStyle mmStyle, MinimapLocation location, Rect contextRect ) 14 | { 15 | int width, height; 16 | width = height = mmStyle.size; 17 | int spacing = mmStyle.spacing; 18 | switch ( location ) 19 | { 20 | case MinimapLocation.TopLeft: 21 | default: 22 | return new Rect( spacing, spacing, width, height ); 23 | 24 | case MinimapLocation.TopRight: 25 | return new Rect( contextRect.width - spacing - width, spacing, width, height ); 26 | 27 | case MinimapLocation.BottomLeft: 28 | return new Rect( spacing, contextRect.height - spacing - height, width, height ); 29 | 30 | case MinimapLocation.BottomRight: 31 | return new Rect( contextRect.width - spacing - width, contextRect.height - spacing - height, width, height ); 32 | } 33 | } 34 | 35 | internal static Transform2d Draw( IEnumerable vertexPositions, Rect drawRect, Rect viewRect, bool showGraphBounds, MinimapStyle style ) 36 | { 37 | // draw black outline 38 | EditorGUI.DrawRect( drawRect.AddBorder( 1f ), Color.black ); 39 | // draw background 40 | EditorGUI.DrawRect( drawRect, style.backgroundColor ); 41 | 42 | // fit vertex positions and viewRect into drawRect 43 | var pointsToFit = vertexPositions.Concat( 44 | new[] { 45 | new Vector2( viewRect.xMin, viewRect.yMin ), 46 | new Vector2( viewRect.xMax, viewRect.yMax ) 47 | } ); 48 | 49 | var mmTransform = ViewUtil.FitPointsIntoRect( pointsToFit, drawRect.Scale( 0.9f ) ); 50 | 51 | // draw view rect 52 | Rect tViewRect = mmTransform.Apply( viewRect ).Intersection( drawRect ); 53 | Util.DrawRectOutline( tViewRect, style.viewRectColor ); 54 | 55 | // draw vertex positions 56 | foreach ( var pos in vertexPositions ) 57 | EditorGUI.DrawRect( Util.CenterRect( mmTransform.Apply( pos ), 2, 2 ), style.vertexMarkerColor ); 58 | 59 | return mmTransform; 60 | } 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /RIDLLProject/View/ViewUtil.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections.Generic; 3 | using RelationsInspector.Extensions; 4 | 5 | namespace RelationsInspector 6 | { 7 | public static class ViewUtil 8 | { 9 | // get a transform that makes the graph fit into the view rect 10 | public static Transform2d FitPointsIntoRect( IEnumerable logicalPositions, Rect displayRect ) 11 | { 12 | // get bounds, ensure they are non-zero 13 | Rect logicalPosBounds = Util.GetBounds( logicalPositions ).ClampExtents( 0.01f, 0.01f, float.MaxValue, float.MaxValue ); 14 | 15 | var logicalExtents = logicalPosBounds.GetExtents(); 16 | var displayExtents = displayRect.GetExtents(); 17 | 18 | // fit logical extents into display extents 19 | var scale = new Vector2( 20 | logicalExtents.x == 0 ? 0 : displayExtents.x / logicalExtents.x, 21 | logicalExtents.y == 0 ? 0 : displayExtents.y / logicalExtents.y 22 | ); 23 | 24 | // translation: put points center into outer rect center 25 | Vector2 pointsCenter = new Vector2( logicalPosBounds.center.x * scale.x, logicalPosBounds.center.y * scale.y ); 26 | Vector2 translation = displayRect.center - pointsCenter; 27 | 28 | var transform = new Transform2d( translation, scale, 0 ); 29 | return transform; 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /RIDLLProject/WorkSpace/IWorkspace.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using UnityEngine; 3 | 4 | namespace RelationsInspector 5 | { 6 | internal interface IWorkspace 7 | { 8 | void OnToolbarGUI(); 9 | Rect OnControlsGUI(); 10 | void OnGUI( Rect drawRect ); 11 | void Update(); 12 | void OnSelectionChange(); 13 | void OnDestroy(); 14 | void OnEvent( Event e ); 15 | 16 | IEnumerable GetEntities(); 17 | IEnumerable GetRelations(); 18 | 19 | void AddTargets( object[] targetsToAdd, Vector2 pos ); 20 | void AddEntity( object vertex, Vector2 position ); 21 | void RemoveEntity( object vertex ); 22 | void ExpandEntity( object entity ); 23 | void FoldEntity( object entity ); 24 | 25 | void CreateRelation( object[] sourceEntities ); 26 | void AddRelation( object source, object target, object tag ); 27 | void RemoveRelation( object source, object target, object tag ); 28 | object[] FindRelations( object entity ); 29 | 30 | void SelectEntityNodes( System.Predicate doSelect ); 31 | void Relayout(); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /RelationsInspectorRelease.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/RelationsInspectorRelease.unitypackage -------------------------------------------------------------------------------- /Releases/1.1.3/RI1.1.3.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/1.1.3/RI1.1.3.unitypackage -------------------------------------------------------------------------------- /Releases/1.1.3/RIDemo1.1.3.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/1.1.3/RIDemo1.1.3.unitypackage -------------------------------------------------------------------------------- /Releases/1.1.4/RelationsInspectorDemo.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/1.1.4/RelationsInspectorDemo.unitypackage -------------------------------------------------------------------------------- /Releases/1.1.4/RelationsInspectorRelease.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/1.1.4/RelationsInspectorRelease.unitypackage -------------------------------------------------------------------------------- /Releases/1.15/RelationsInspectorDemo.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/1.15/RelationsInspectorDemo.unitypackage -------------------------------------------------------------------------------- /Releases/1.15/RelationsInspectorRelease.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/1.15/RelationsInspectorRelease.unitypackage -------------------------------------------------------------------------------- /Releases/Demo1.0.5872.22010/RelationsInspectorDemo.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Demo1.0.5872.22010/RelationsInspectorDemo.unitypackage -------------------------------------------------------------------------------- /Releases/Demo1.0.5898.2791/RelationsInspectorDemo.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Demo1.0.5898.2791/RelationsInspectorDemo.unitypackage -------------------------------------------------------------------------------- /Releases/Demo1.1.0.0/RelationsInspectorDemo.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Demo1.1.0.0/RelationsInspectorDemo.unitypackage -------------------------------------------------------------------------------- /Releases/Demo1.1.1/RelationsInspectorDemo.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Demo1.1.1/RelationsInspectorDemo.unitypackage -------------------------------------------------------------------------------- /Releases/Demo1.1.2/RelationsInspectorDemo.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Demo1.1.2/RelationsInspectorDemo.unitypackage -------------------------------------------------------------------------------- /Releases/Release1.0.5862.27937/RelationsInspector.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Release1.0.5862.27937/RelationsInspector.unitypackage -------------------------------------------------------------------------------- /Releases/Release1.0.5898.2780/RelationsInspector.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Release1.0.5898.2780/RelationsInspector.unitypackage -------------------------------------------------------------------------------- /Releases/Release1.1.0.0/RelationsInspector.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Release1.1.0.0/RelationsInspector.unitypackage -------------------------------------------------------------------------------- /Releases/Release1.1.1/RelationsInspector.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Release1.1.1/RelationsInspector.unitypackage -------------------------------------------------------------------------------- /Releases/Release1.1.2/RelationsInspector.unitypackage: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/seldomU/relationsinspector/a5e61b1102d8a965804c7d5e37430b4f85ac769d/Releases/Release1.1.2/RelationsInspector.unitypackage -------------------------------------------------------------------------------- /UnityVS.RelationsInspector.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 2015 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UnityVS.RelationsInspector.CSharp.Plugins", "UnityVS.RelationsInspector.CSharp.Plugins.csproj", "{6056C4D6-E376-537E-C757-5E2481C312EA}" 5 | EndProject 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UnityVS.RelationsInspector.CSharp.Editor.Plugins", "UnityVS.RelationsInspector.CSharp.Editor.Plugins.csproj", "{3219B92A-AD39-20FD-EF13-B5E3BC755FF0}" 7 | EndProject 8 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RelationsInspectorLib", "RIDLLProject\RelationsInspectorLib.csproj", "{8564B945-82F3-4C72-9661-3D6A6B311764}" 9 | EndProject 10 | Global 11 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 12 | Debug|Any CPU = Debug|Any CPU 13 | Release|Any CPU = Release|Any CPU 14 | EndGlobalSection 15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 16 | {6056C4D6-E376-537E-C757-5E2481C312EA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 17 | {6056C4D6-E376-537E-C757-5E2481C312EA}.Debug|Any CPU.Build.0 = Debug|Any CPU 18 | {6056C4D6-E376-537E-C757-5E2481C312EA}.Release|Any CPU.ActiveCfg = Release|Any CPU 19 | {6056C4D6-E376-537E-C757-5E2481C312EA}.Release|Any CPU.Build.0 = Release|Any CPU 20 | {3219B92A-AD39-20FD-EF13-B5E3BC755FF0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {3219B92A-AD39-20FD-EF13-B5E3BC755FF0}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {3219B92A-AD39-20FD-EF13-B5E3BC755FF0}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {3219B92A-AD39-20FD-EF13-B5E3BC755FF0}.Release|Any CPU.Build.0 = Release|Any CPU 24 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 25 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Debug|Any CPU.Build.0 = Debug|Any CPU 26 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Release|Any CPU.ActiveCfg = Release|Any CPU 27 | {8564B945-82F3-4C72-9661-3D6A6B311764}.Release|Any CPU.Build.0 = Release|Any CPU 28 | EndGlobalSection 29 | GlobalSection(SolutionProperties) = preSolution 30 | HideSolutionNode = FALSE 31 | EndGlobalSection 32 | EndGlobal 33 | -------------------------------------------------------------------------------- /build.bat: -------------------------------------------------------------------------------- 1 | "C:\Program Files (x86)\MSBuild\14.0\Bin\msbuild.exe" MainPackage.msbuild /t:Binary /p:Configuration=Release /p:DemoMode=Release /p:UnityEditorBinaryPath="C:\Program Files (x86)\Unity 5.5\Editor\Unity.exe" --------------------------------------------------------------------------------