It’s just that the way isConnected is determined in the editor, is after calling the FlowNode.GatherPorts -> ValidateConnections.
ValidateConnections is currently wrapped in a #if UNITY_EDITOR, because the way validations are made a performance costly (lots of foreach iterations and type conversion checks), which are otherwise not really required in runtime. Unfortunately or not, isConnected is set from within this Validation method.
So, if we were to simply remove #if UNITY_EDITOR and run ValidateConnections method, while isConnected will work correctly, there will be a performance cost.
Thus, the solution would be to find another way to determine isConnected and move it outside of the Validate methods, which requires some refactoring to make sure everything works as intended.
🙂
Join us on Discord: https://discord.gg/97q2Rjh
Login
Register
By registering on this website you agree to our Privacy Policy.