Pause Menus/Multiple Settings Screens/Inventory/Etc

0 favourites
  • 4 posts
From the Asset Store
A well commented template with list menus and shops to use in your top-down RPGs or metroidvania games!
  • Hey all,

    I'm just curious, for people that have added elaborate menus/settings to their game, how they set it up and pros and cons they have found.

    I don't just mean a simple pause menu that is one screen. Think multiple screens or options, whether it is settings like video/audio/gameplay/controls, or gameplay menus like inventory and other sub menus.

    The way I see it, I can think of three different ways to set it up:

    • Layer: Set up the menus on a layer and toggle visibility & interactive
    • Events: Create & Destroy all menu aspects (sprites, text, etc) via events
    • Layouts: Create a separate layout to switch to for these menus/settings

    The first one seems the simplest to setup, with just creating hidden layers for everything. But it also seems the messiest, as the amount of hidden objects in your project will grow. Has anyone run into performance issues with this, or bugs to troubleshoot? (probably user-error bugs, like accidentally destroying/moving menu objects)

    The third one also seems easy to setup, but depending on the game, might have a difficult time switching back to the original layout and having everything where it was before.

    The second one seems optimal to me. But it does seem a tad more tedious if it isn't quite necessary.

    Open floor - Just wanted to throw it out here to learn from anyone else's experiences or see if any of my thoughts are flawed. Feel free to suggest any other ideas or bring up any related points or questions.

    Thanks.

  • I generally create and destroy as needed, but on a dedicated UI menu layer, so a bit of both 1 and 2. This layer is separate from gameplay huds/UI layer. That's more of a personal organizational preference thing than a performance issue though

    I don't like having hidden objects/layers that aren't serving any specific purpose. I also generate my menu item positions dynamically via events to be flexible. I imagine for someone who likes utilizing the layout editor to place and layout their menus, hiding and un hiding layers would be more suitable.

    I doubt there is any performance impact worth thinking about at all, unless you're doing something really crazy with your menus. For something like an inventory or character sheet, I'd definitely create it as needed, but for the reason that the contents are dynamic rather than any performance concern.

  • Thanks for sharing!

    I don't like having hidden objects/layers that aren't serving any specific purpose...I doubt there is any performance impact worth thinking about at all

    Yeah, I don't think so either and feel the same, plus I always enjoy having fewer objects when using the debug preview, ha.

    I also generate my menu item positions dynamically via events to be flexible

    I'll probably end up doing this, too, as it is less tedious for me to center and evenly space objects in events.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • You can have a layout that has many different "windows" created (for pause, graphics options, etc), where you position all your buttons and options onto a "window" sprite as a hierarchy, and give the window a template name, such as "Menu_Pause".

    Then, at any time, you can create the window object with the template name, and make sure to tick the option to spawn the entire hierarchy when creating the window, and it will spawn as expected.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)