Exit flow for Branch node
tracked
hackspanner
There should be a third output flow called Exit or Done on the Branch node, that always executes after either branch flow completes. This would allow you to merge the flow after branching.
Log In
Momo the Monster
updated the status to
tracked
re-considering this now.
Momo the Monster
updated the status to
closed
You can now merge flows without needing this, assuming we can consider this closed.
BlueAmulet
Since February 23 you can now merge execution paths in Udon, except all nodes after the merge point end up duplicated in the resulting assembly. Other node based scripting solutions such as Bolt and uNode also have this problem, all nodes after the merge point show up twice in their respective C# preview.
Having a third output flow for Branch nodes would allow for smaller cleaner output and imho would not be clutter or overly complex. Both uNode and Nottorus handle their If nodes with a third output called "Finished"
Ashaka
I also disagree with this. Having an exit flow just adds more clutter and hurts the simplicity of the branch node. I could see this being handy in some circumstances, but I think it would make the graph a bit hard to read. It just gives the branch too many responsibilities (evaluate bool, then choose direction, vs evaluate bool, choose direction, and then come back and take a different route). I know the loop has an exit route, but that needs to be there for the loop to be effective. Here, not so much.
E
EvolvedAnt
I disagree with the suggested solution. You should be able to merge nodes regardless of adding new output flows. Having more output flows as a workaround is more complex and should be unnecessary. The flow of execution is not ambiguous, a branch can either go one way, or the other. This is already proven to be possible as other node based scripting languages in Unity already support it without custom output nodes. I have created an example image from Bolt and included it below:
Photo Viewer
View photos in a modal