From e279f671f0c9e7fb7cbb98ae44aedf92220d8919 Mon Sep 17 00:00:00 2001 From: Rhys van der Waerden Date: Wed, 18 May 2022 11:19:26 +1000 Subject: [PATCH] Flatten hierarchy when searching for attributes (#216) Fixes #216 --- .../Runtime/Elements/BaseNode.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Assets/com.alelievr.NodeGraphProcessor/Runtime/Elements/BaseNode.cs b/Assets/com.alelievr.NodeGraphProcessor/Runtime/Elements/BaseNode.cs index 0338c14b..57e5fd14 100644 --- a/Assets/com.alelievr.NodeGraphProcessor/Runtime/Elements/BaseNode.cs +++ b/Assets/com.alelievr.NodeGraphProcessor/Runtime/Elements/BaseNode.cs @@ -230,7 +230,7 @@ void InitializeCustomPortTypeMethods() Type baseType = GetType(); while (true) { - methods = baseType.GetMethods(BindingFlags.NonPublic | BindingFlags.Instance); + methods = baseType.GetMethods(BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.FlattenHierarchy); foreach (var method in methods) { var typeBehaviors = method.GetCustomAttributes().ToArray();