I want to create a settings screen.

The sample project ‘Menu Sample’ includes an option to change the window size, and I’ve been trying to create this feature from scratch by opening the options screen, but I haven’t been able to make it work.

Specifically, when I attempt to ‘display the menu scene’ using an execution action within the script, the running game terminates. Since no error message is displayed, I don’t believe it’s an error…

I’m modifying settings and items without understanding their purpose or meaning, so this is expected, but I can’t identify the cause. What parts should I check and configure to resolve this?

Hello, I’ll try to help. How is your structure set up to call the menu? For it to work correctly, you need to:

  • Create a Menu Scene:
    Create a Menu Scene.

  • Create a Game Object to be the actual menu and place it on the CanvasLayer of the Menu Scene. This will be the actual menu and will contain the visual script; Menu Scenes cannot have visual scripts on them:
    Create a Game Object to be the actual menu and place it on the CanvasLayer of the Menu Scene. This will be the actual menu and will contain the Visual Script. Menu Scenes cannot have Visual Scripts on them.

Can you verify you have this setup?

Here is a video that may also help:

I thought it was a terrible question myself, but thank you for your advice.

I recreated the project and confirmed that it works without issues! Since I already deleted the original project, I don’t know the cause, but I don’t think I’ll ask the same question again.

Also, thank you for introducing the video. I have subscribed to your channel.

There were parts I couldn’t understand just by watching once, but it was educational as it covered detailed techniques.

2 Likes