TomGrobbe / MenuAPI

FiveM C# Menu API. Designed specifically as a replacement of NativeUI for vMenu. Full safezone scaling supported, both left and right aligned menus supported.
https://docs.vespura.com/mapi
62 stars 45 forks source link

PreventExitingMenu not working #10

Closed n00el closed 5 years ago

n00el commented 5 years ago

Okay, I have one menu, with only one item, and I have this code:

MenuController.MenuAlignment = MenuController.MenuAlignmentOption.Right;
MenuController.PreventExitingMenu = true;

The aligment is working, I can set it to the left/to the right, but the PreventExitingMenu not doing anything. I can still exit the menu with the esc button, the backspace etc..

TomGrobbe commented 5 years ago

prevent exiting menu is actually incorrectly named, but can't be changed due to backwards compatibility. All it does is prevent opening the pause menu when pressing ESC or P while the menu is open. Use the DisableBackButtons property to disable the ESC/backspace buttons.