Navigate away from custom panel, go to scene/label from script?


I have a custom panel where the player is allowed to make selections for activities during different times in the day (morning, afternoon, and evening), so the hope is that the scene flow would go according to the player choices.

I know how to set and read vinoma variables from script, and that seems to be okay. I’m having trouble figuring out how to navigate away from my custom panel, get back into the scene flow with a custom button/script after having made the selections, and calling a custom script to navigate to a different scene/label based on the variables that were set in the activity selection phase. Is there a method in VinomaSceneController that would facilitate this?

(Leslie Young) #2

You can use VinomaSceneController.Instance.Goto(VinomaGotoOption opt, string sceneName, string labelName); to go to a specific VInoma Scene and position in that scene.

opt = VinomaGotoOption.SceneTop/ SceneEnd navigates the currently active scene. So sceneName and labelName can be null.

opt = VinomaGotoOption.Label goes to a label in the currently active scene, so sceneName can be null.

opt = VinomaGotoOption.Scene will navigate to the specified sceneName, and optional label in that scene.


Works great, thanks! :slight_smile:


I am having some trouble with this. I’ve created a panel of buttons that are present through the game for navigation. In my Vinoma scene I have a Wait:Forever so it will just sit at that page until a different button is clicked. It does not seem to care about my function

public void ChangeScene(string scene)
{ VinomaSceneController.Instance.Goto(VinomaGotoOption.SceneTop, scene, scene + “Top”);

As of right now, it sits at Wait:Forever even if I click the buttons, any chance I could get some help?

(Leslie Young) #5

VinomaGotoOption.SceneTop/ SceneEnd navigates the currently active scene. So sceneName and labelName can be null.

You simply telling it to go to the top of the currently active scene so it will end up again at the Wait action of that scene.

You also do not need to pass a Label if you want to end up at the top/start of the scene.

You probably want this. Don’t just copy-paste. Ask if you do not understand what the code means, though it should be clear from my previous post in this thread.

public void ChangeScene(string scene)
    VinomaSceneController.Instance.Goto(VinomaGotoOption.Scene, scene, null);


Nope, that’s exactly what I need, I had a feeling it was with my method call. Thank you!