Reply To: Scenario with Nodecanvas

Forums 💬 NodeCanvas ⚙️ Support Scenario with Nodecanvas Reply To: Scenario with Nodecanvas

#18764
wilbert
Participant

    It is a (simplified version of a) standalone script that is called to create the List of scenario-steps now. (I believe it is called a constructor in programming terms ?)

    I make a List to hold these ScenarioStep objects with the data to which ScenarioObjects to interacts with (Click on mostly) and the ActionObjects that have to be animated to perform the actions by setting the Mecanin state with the ObjectState trigger

    So to create the scenario I fill a List with these ScenarioStep Objects on StartUp

    This would create a scenariostep that will trigger the “trCP1ScreenPrestart” state on the goControlPanel1 gameobject when the gobtPrestart gameobject is clicked.

    A ScenarioManager script is then running in the scene that steps through the list and checks if an object that is clicked is the “current ScenarioObject” if it is the correct object it fires the Trigger and goes to the next step in the List. If it isn’t it shows an error message.
    https://www.youtube.com/watch?v=XgPSaYkTZY4

    My main idea is that with Nodecanvas I can turn these ScenarioSteps into nodes and by connecting them in a FSM I have a more visually and easier way to create and run these scenario’s.

    I hope this makes it a is bit more clear to you ?