Reply To: Scenario with Nodecanvas

NodeCanvas Forums Support Scenario with Nodecanvas Reply To: Scenario with Nodecanvas

#10633
Gavalakis
Keymaster

Hello and thanks for info.
If you are willing to do some redesing, you could implement the steps as FSM state actions.
For example, you can have a custom action (ScenatioStep), that has a GameObject variable which is the scenarioObject that needs to be clicked. Then in the action’s update check if that object is clicked and send and event to the FSM “Corrent” otherwise “Wrong” for example. Here is what I did. You can expand on this if you want to add more funcitonality.

ScenarioSteppingFSM

Then I add this action in each state that represents a scenario step and add a “Check Event” condition on it’s transitions to check whether the event send from the action is “Correct” or “Wrong”.

So, if I click in order Sphere1, Sphere2, Sphere3, then everything will go through the “Correct” path.
Let me know if this works for you, or you had something different in mind.

Thanks.

Join us on Discord: https://discord.gg/97q2Rjh

Attachments:
  1. ScenarioSteppingFSM.png