Common events running based on input

I want to make a system that doesn't require the buttons seen on the message box. If the player presses escape or a different button, it will open up a common event, leading to a menu or the settings, etc.

Or, for minigames - If the player presses a button, it will have an effect in that minigame. Like, freezing the screen and opening a menu or something. Is this possible? Preferably, without much coding, and using only the blocks.

Original thread: https://forums.rpgmakerweb.com/threads/common-events-running-based-on-input.149800/