I just came across an issue where I needed the logic “if ((A && B) || C) then transition to the next state”. How would you do sth like this? There is the possibility to chose “All true required” or “Any true suffice” from under the condition list. But What if I need both, like in the example? I solved this by introducing an empty in-between state to where I can transition and from there I immediately transition to where I wanted to go.
So the direct connection uses A&&B logic and the indirect connection through an empty state uses the C only condition.
Any suggestions?
Have you been thinking about introducing multiple connections between two states? 🙂
Like in Mecanim for example.
Unfortunately this is not currently possible. It used to be possible by using two separate conditions lists within another condition list but because it was quite complicated to manage, I removed the ability to nest condition lists within other condition lists for clarity.
Regarding multiple transitions, even though the framework supports this already I’ve not allowed it only because I don’t yet know how to show the condition information UI of the transitions when there are multiples. I will certainly though take another look at how the UI in the middle of the transitions could be shown for multiple transitions and hopefully come by a better solution than the last time! 🙂
I purchased NC yesterday and been digging into it.
Is this still true?
How would you suggest I solve the issue, if this would be a requirment?
Or is this an indicator, that something’s wrong with the FSM design?
I am not yet sure, if I can think of a case, where this is really needed, but I have to be prepared.
One solution I can think of is create a transition (bool) property and have some logic via code … and then only this bool is checked.
How would you do it? Don’t wanna work against the system.
Thanks for purchasing NC.
Are you referring to the case of “if ((A && B) || C)” ?
If so, a simple solution would be to just create a custom Condition Task, to perform the checks you want it to.
You proposed solution of simply checking a boolean property and have that property do the relevant checks instead, is also just fine as well!
There is nothing wrong with the FSM design at all by the way. 🙂