Simon Rodriguez
da0f291a44
converted PortDataCache to a dictionary that holds a dictionary of fieldname and port indexed by type. Removed serialized from PortDataCache as it was not being saved anywhere.
2022-11-27 15:59:59 +01:00
Simon Rodriguez
c7debc2346
Added ifdef 2021_3_or_newer where Unity upgraded to net standard 2.1 where Dictionary.EnsureCapacity is added.
2022-11-27 15:07:37 +01:00
Simon Rodriguez
445af6e703
most new unity packages starts with Unity.xx, this reduces the number of assemblies to look through by ~30
2022-11-06 10:17:07 +01:00
Simon Rodriguez
f77fa501f1
removed lookup to list that the tryget is already doing
2022-11-02 09:30:49 +01:00
Simon Rodriguez
f167313957
use string substring instead of allocating a array with the two strings in it.
2022-11-02 09:12:06 +01:00
Simon Rodriguez
bdbb287f00
use array instead of list in a enumeration we wont change
2022-11-02 09:11:27 +01:00
Simon Rodriguez
5201808eff
reuse staticPorts dictionary to reduce number of allocations of memory, clear after every use and ensure capacity when we know we are going to add many entries
2022-11-02 09:10:15 +01:00
Simon Rodriguez
a077ca136b
cache the AssemblyQualifiedName string, reduces number of allocations and garbage collection in projects with many nodes
2022-11-02 09:08:57 +01:00
Thor Brigsted
0e7e4aa254
Added public overrides for custom NodePort CanConnect conditions in GraphEditor
2022-09-21 13:53:28 +02:00
Simon Rodriguez
e1b564db1c
added error handling
2021-05-04 08:38:25 +02:00
Simon Rodriguez
3287575dcd
moved reflection code to cache part in initialization
2021-05-04 08:29:16 +02:00
Simon Rodriguez
2f69c4350d
Added support for unitys FormerlySerializedAsAttribute. It reconnects ports that has the old name to its new name.
2021-05-01 18:47:39 +02:00
Jeff Campbell
bbfc44b04f
Added fix for duplicate node fields found
...
* Added fix for duplicate node fields found while iterating through base fields; on 2019.3 using .Net 20 getting the fields of the node type will return all base type fields as well. This results in the iteration up through the base classes and adding their instance fields resulting in duplicates which causes errors on node creation when assigning port information.
2020-02-28 22:52:30 +01:00
Gökhan Kurt
c9e1ef1c92
Skip Microsoft assemblies while building node cache ( #234 )
2020-02-13 23:38:17 +01:00
Lumos
f9200ae6a8
Change the serialised type of dynamic port lists defined as lists/arrays to match the respective element type. ( #232 )
...
This is logical, given that xNode already draws such dynamic ports as belonging to the element type.
2020-02-13 22:48:59 +01:00
Lumos
7e93ffe4b7
Fix for the dynamic port "serialisation desync" problem. ( #223 )
...
* Exclude strings from array types manually to prevent them from being treated as char arrays.
2020-01-21 08:01:57 +01:00
Thor Brigsted
80c8b36ab8
Removed unused hashset
2019-08-05 00:51:47 +02:00
Thor Brigsted
f38ff44261
Fixed #175 - Adjusted skipped DLLs check
2019-08-05 00:26:10 +02:00
Simon Rodriguez
723ecc43c1
Ports losing connections ( #171 )
...
* clear connections before removing port, so the connected nodes don't have invalid references.
* Try reconnecting the previous ports connections in the new port.
Skip reconnecting if the port is dynamic or if the direction has changed.
2019-07-10 00:07:23 +01:00
thiezar
29f0194eef
Allow current assembly nodes to be cached ( #153 )
2019-06-13 20:17:58 +02:00
Thor Brigsted
71defcbdd5
Implemented typeConstraint in InputAttribute
2019-02-16 02:36:42 +01:00
Thor Brigsted
8c731a9947
Fixed #100 again
2019-01-21 21:07:07 +01:00
Thor Brigsted
4c9264fed5
Fixed #100
2019-01-20 22:01:26 +01:00
Thor Brigsted
ff97cc4494
Switched Dict.ContainsKey out with Dict.TryGetValue for performance gain.
2018-09-09 18:25:41 +02:00
Joram
4bfb6c4b8b
optimized dll caching
2018-06-18 20:52:58 +02:00
Joram
0331bde4e1
Plugin folder get recognized as seperate dll
2018-06-18 19:31:44 +02:00
Thor Brigsted
6d6a6abd9e
Added support for usage from a DLL #23
2018-03-25 12:51:02 +02:00
Thor Brigsted
fcbd48b0be
Improved error message
2018-01-22 01:19:23 +01:00
Thor Brigsted
55fb7586d8
Register ConnectionType changes and update existing static NodePorts
2018-01-21 22:45:20 +01:00
Thor Brigsted
aa54950611
Fixed minor bug (error message)
2018-01-21 11:20:23 +01:00
Thor Kramer Brigsted
4f65fcefc6
Fixed bug that would cause nodes without static ports to not properly remove old static ports
2017-11-07 10:02:58 +01:00
Thor Brigsted
c6a4735c71
Renamed to xNode
...
Added XNode and XNodeEDitor namespaces
Removed unnecessary usings
2017-11-05 23:42:31 +01:00
Thor Kramer Brigsted
8eff75fa7f
Bug fixes
2017-11-02 16:17:28 +01:00
Thor Kramer Brigsted
d3bb36fe0e
Big update: Warning: Updating to this commit will break all node connections.
...
Internal NodePorts now uses dicts instead of lists. This is faster and more manageable.
Added instance ports.
Added Node.Ports, Node.Outputs, Node.Inputs, Node.InstanceOutputs, Node.InstanceInputs
Changed public GetInputByFieldName to GetInputValue and GetInputPort
2017-11-02 14:54:03 +01:00
Thor Brigsted
64282028aa
Code FixFormat
...
None of the code was changed, just moved around.
2017-10-14 08:37:33 +02:00
Thor Brigsted
8ce0d63903
NodeDataCache changed from ScriptableObject to static class.
...
Nodes still don't load properly, but we're getting there.
2017-10-12 00:18:40 +02:00
Thor
d608eaab9a
NodeDataCache initialization now works correctly
...
Still needs work on GetPorts, keep connections, disconnect invalid, etc.
2017-10-11 09:03:20 +02:00
Thor
963eb84edb
Possible solution found. NodeGraph now initializes NodeDataCache before creating any nodes.
2017-10-11 08:36:36 +02:00
Thor Brigsted
984364f08f
Still haven't found a solution to initializing a static scriptableObject instance
2017-10-10 23:53:27 +02:00
Thor Brigsted
d52ecf1931
Fixed compile errors. Still doesn't initialize correctly, nor saves connections
2017-10-10 00:30:24 +02:00
Thor Brigsted
76e8b70316
Initialization performance updates (wip)
2017-10-09 19:52:41 +02:00