How to check if player is on menu screen

Could anyone by chance tell me how to implement a conditional branch script call to check if the player has the menu (with the commands: skills, items, etc.) opened or closed? Any input would be greatly appreciated! (Or if there's another means to check if the player is on the menu screen, that would be just as helpful.)


::edit:: Apologies if I put this in the wrong section.
The map is a scene.  The menu is a scene.  Only one scene can be active at a time.  This means if the player DOES have the menu open, the map will NOT be open, and events on the map will not be running.  Therefore any conditional branch in an event that is trying to check if the player has the menu open will not work, because if the menu IS open, the event will not be running.  If the event is running and the conditional branch can actually be executed, it means the menu is closed.


Maybe you should say what you're trying to achieve, and we can help you with the method.
Thanks for explaining that, Shaz.

I'm trying to work out something similar to the old 2k3 method of custom menus by using pictures along with a few other plugins (including Yanfly's "common event menu" plugin and Yanfly's "Button Common Events" plugin).

I know by setting up a common event (via Yanfly's "Button Common Events") I can show a picture and open the menu scene when a button is pressed (the cancel button, for example) via event commands, but I can't figure out a convenient way to remove the picture when returning to the map scene. I know there's always the method of having an event on every map that checks, but I guess I was hoping there might be a simpler way to check rather than each map requiring an event to check.

Hopefully this explanation decently clarifies my intent. (I find it hard to explain sometimes what I'm getting at in my head versus in words/text.)
If you are opening the menu with a Call Menu command, you can simply add the Erase Picture command afterwards.  When you have an event (or common event) that changes the scene, as soon as it comes back to the map after that scene is closed, the event will continue to run from where it left off.
Thank you Shaz, I think I overlooked how extremely simple that was. Thanks for your solution! Case solved and thread can be closed.
I'm not familiar with the plugins or with your methods.  Give it a test and make sure it works first, and if it does, you can report your post and ask for the thread to be closed.  If it doesn't work, you can post what you've got (screenshot of the event/common event) and state what is actually happening, and we can help you troubleshoot further.

Original thread: https://forums.rpgmakerweb.com/threads/how-to-check-if-player-is-on-menu-screen.68906/