| AddMenuItem | Appends a new item to the end of a menu. |
| CancelClientMenu | Cancels a menu on a client. This will only affect non-external menus. |
| CancelMenu | Cancels a menu from displaying on all clients. While the
cancellation is in progress, this menu cannot be re-displayed
to any clients.
The menu may still exist on the client's screen after this command.
This simply verifies that the menu is not being used anywhere.
If any vote is in progress on a menu, it will be cancelled. |
| CancelVote | Cancels the vote in progress. |
| CanPanelDrawFlags | Returns whether or not the given drawing flags are supported by
the menu style. |
| CheckVoteDelay | Returns the number of seconds you should "wait" before displaying
a publicly invocable menu. This number is the time remaining until
(last_vote + sm_vote_delay). |
| CreateMenu | Creates a new, empty menu using the default style. |
| CreateMenuEx | Creates a Menu from a MenuStyle. The Handle must be closed with
CloseHandle(). |
| CreatePanel | Creates a MenuPanel from a MenuStyle. Panels are used for drawing raw
menus without any extra helper functions. The Handle must be closed
with CloseHandle(). |
| CreatePanelFromMenu | Creates a raw MenuPanel based off the menu's style.
The Handle must be freed with CloseHandle(). |
| DisplayMenu | Displays a menu to a client. |
| DisplayMenuAtItem | Displays a menu to a client, starting from the given item. |
| DrawPanelItem | Draws an item on a panel. If the item takes up a slot, the position
is returned. |
| DrawPanelText | Draws a raw line of text on a panel, without any markup other than a newline. |
| GetClientMenu | Returns whether a client is viewing a menu. |
| GetMaxPageItems | Returns a style's maximum items per page. |
| GetMenuExitBackButton | Returns whether or not the menu has an "exit back" button. By default,
menus do not have an exit back button.
Exit Back buttons appear as "Back" on page 1 of paginated menus and have
functionality defined by the user in MenuEnd_ExitBack. |
| GetMenuExitButton | Returns whether or not the menu has an exit button.
By default, menus have an exit button. |
| GetMenuItem | Retrieves information about a menu item. |
| GetMenuItemCount | Returns the number of items in a menu. |
| GetMenuOptionFlags | Retrieves a menu's option flags. |
| GetMenuPagination | Returns a menu's pagination setting. |
| GetMenuSelectionPosition | Returns the first item on the page of a currently selected menu.
This is only valid inside a MenuAction_Select callback. |
| GetMenuStyle | Returns a menu's MenuStyle Handle. The Handle
is global and cannot be freed. |
| GetMenuStyleHandle | Returns a style's global Handle. |
| GetMenuTitle | Returns the text of a menu's title. |
| GetMenuVoteInfo | Retrieves voting information from MenuAction_VoteEnd. |
| GetPanelCurrentKey | Returns the current key position. |
| GetPanelStyle | Returns a MenuPanel's parent style. |
| GetPanelTextRemaining | Returns the amount of text the menu can still hold. If this is
limit is reached or overflowed, the text is silently truncated.
Radio menus: Currently 511 characters (512 bytes).
Valve menus: Currently -1 (no meaning). |
| InsertMenuItem | Inserts an item into the menu before a certain position; the new item will
be at the given position and all next items pushed forward. |
| InternalShowMenu | This function is provided for legacy code only. Some older plugins may use
network messages instead of the panel API. This function wraps the panel
API for eased portability into the SourceMod menu system.
This function is only usable with the Radio Menu style. You do not need to
split up your menu into multiple packets; SourceMod will break the string
up internally. |
| IsClientInVotePool | Returns whether a client is in the pool of clients allowed
to participate in the current vote. This is determined by
the client list passed to VoteMenu(). |
| IsNewVoteAllowed | Quick stock to determine whether voting is allowed. This doesn't let you
fine-tune a reason for not voting, so it's not recommended for lazily
telling clients that voting isn't allowed. |
| IsVoteInProgress | Returns whether a vote is in progress. |
| MenuSetClientMapping | Fills the client vote option mapping with user supplied values. |
| MenuShufflePerClient | Generates a per-client random mapping for the current vote options. |
| RedrawClientVoteMenu | Redraws the current vote menu to a client in the voting pool. |
| RedrawMenuItem | Redraws menu text from inside a MenuAction_DisplayItem callback. |
| RemoveAllMenuItems | Removes all items from a menu. |
| RemoveMenuItem | Removes an item from the menu. |
| SendPanelToClient | Sends a panel to a client. Unlike full menus, the handler
function will only receive the following actions, both of
which will have INVALID_HANDLE for a menu, and the client
as param1.
MenuAction_Select (param2 will be the key pressed)
MenuAction_Cancel (param2 will be the reason)
Also, if the menu fails to display, no callbacks will be called. |
| SetMenuExitBackButton | Sets whether or not the menu has an "exit back" button. By default, menus
do not have an exit back button.
Exit Back buttons appear as "Back" on page 1 of paginated menus and have
functionality defined by the user in MenuEnd_ExitBack. |
| SetMenuExitButton | Sets whether or not the menu has an exit button. By default, paginated menus
have an exit button.
If a menu's pagination is changed to MENU_NO_PAGINATION, and the pagination
was previously a different value, then the Exit button status is changed to
false. It must be explicitly re-enabled afterwards.
If a non-paginated menu has an exit button, then at most 9 items will be
displayed. |
| SetMenuNoVoteButton | Sets whether or not the menu has a "no vote" button in slot 1.
By default, menus do not have a no vote button. |
| SetMenuOptionFlags | Sets a menu's option flags.
If a certain bit is not supported, it will be stripped before being set.
See SetMenuExitButton() for information on Exit buttons.
See SetMenuExitBackButton() for information on Exit Back buttons. |
| SetMenuPagination | Sets whether the menu should be paginated or not.
If itemsPerPage is MENU_NO_PAGINATION, and the exit button flag is set,
then the exit button flag is removed. It can be re-applied if desired. |
| SetMenuTitle | Sets the menu's default title/instruction message. |
| SetPanelCurrentKey | Sets the next key position. This cannot be used
to traverse backwards. |
| SetPanelKeys | Sets the selectable key map of a panel. This is not supported by
all styles (only by Radio, as of this writing). |
| SetPanelTitle | Sets the panel's title. |
| SetVoteResultCallback | Sets an advanced vote handling callback. If this callback is set,
MenuAction_VoteEnd will not be called. |
| VoteMenu | Broadcasts a menu to a list of clients. The most selected item will be
returned through MenuAction_End. On a tie, a random item will be returned
from a list of the tied items.
Note that MenuAction_VoteEnd and MenuAction_VoteStart are both
default callbacks and do not need to be enabled. |
| VoteMenuToAll | Sends a vote menu to all clients. See VoteMenu() for more information. |