View Single Post
Leech_v2
Senior Member
Join Date: Mar 2011
Location: Chinese GuangDong
Old 11-30-2021 , 02:47   Re: How to hook menu display events
Reply With Quote #4

Quote:
Originally Posted by CrazY. View Post
Assuming you want to hook amxx menus as well, the above suggestion will not work alone.
What you can do is combine that with orpheu. Hook amxx show_menu, Menu:: Display and Menu::Close, there is no alternative.

If you need that for VGUI menus it's hacky. You'll have to hook the message VGUIMenu, dispatch a Close Event on the current menu and Display Event on the menu that is being displayed.

There may be an alternative but you will have to explain what you are trying to do and why you need that.
Players can create menus repeatedly by pressing z, x, c, or otherwise to accumulate menu objects on the server
Leech_v2 is offline