Monarch - Popping Multiple Screens

I have a screen stack like so:

| submenu_c (popup on popup)
| submenu_b (popup on popup)
| menu_a (popup)
| game_world

I want to pop menus a, b, and c off the stack simultaneously when the user presses enter, as a convenient way to close all menus and return to the game. I don’t see a straightforward function call for this in Monarch’s API.

You could do three calls to monarch.back() to get back to the game_world screen. Another alternative is to call monarch.show("game_world", { clear = true }). This will show game_world and clear any screens “above” the screen in question.

3 Likes