ai-radialmenu
The radial menu on F3, with built-in actions and the items every other script adds. Answers the qb-radialmenu and tgiann-radialmenu-target APIs.
ai-radialmenu is the round menu that opens on F3. It holds a few built-in actions and every item other scripts add: the police menu for officers, the prison time for prisoners, vehicle actions while driving, and so on. Each item shows only when it makes sense (on duty, in a vehicle, holding an item).
What it does in the game
- Built-in items. Inventory (opens the inventory), HUD settings (opens the running HUD's own settings, shown only when the HUD has a settings menu), Keys (AI Core's keys screen: a keyboard with every key that does something and the player's own bindings), and a Vehicle category while in a vehicle.
- Vehicle category. Engine on / off, Trunk and Hood for the driver. The engine item never starts a car the player has no key for. Other scripts add their own vehicle items here (keys, seats, doors).
- Items from other scripts. Added and removed live, and gone when that script stops.
- Sub menus. A category opens its own wheel. Hovering a category shows its items as small icons around it.
- Pages. Ten items per page. Keys 1 to 9 and 0 pick an item; the arrows, the mouse wheel or the pager turn the page.
- Going back. Backspace or a right click goes back a level; the centre button goes back or closes; Escape, the open key again, or a click outside the cards closes it.
- While down. When the player is dead or downed, only items made for that state show. If there are none, the wheel does not open.
Installation
The AI Core txAdmin recipe installs it. By hand: put the folder in resources/[ai]/ and add ensure ai-radialmenu to server.cfg after ensure ai-core. It needs OneSync and ai-core. It has no database table.
Do not run qb-radialmenu or tgiann-radialmenu-target next to it: both wheels would fight over the key. AI Core reports them in the console and refuses players while both run.
Panel settings
None. ai-radialmenu has no tab in the admin panel: the items come from the scripts, and the key is set in the Keybinds tab.
Commands
None.
Keybinds
| Default key | What it does | Name in GTA settings |
|---|---|---|
| F3 | Opens the radial menu (press again to close) | Open the radial menu |
The key also shows in the HUD's key hints as "Menu". Change the default for everyone in the panel's Keybinds tab; each player can change their own in GTA's key settings.
Works with other scripts
- qb-radialmenu (
provide): scripts that callexports['qb-radialmenu']:AddOption(...)/RemoveOption(...)add their items to this wheel. - tgiann-radialmenu-target (
provide): its client menu exports (AddMenuItem,RegisterSubMenu,DisableMenu, ...) work on this wheel. - ox_lib's radial cannot be answered: items of scripts written for
lib.addRadialItemshow in ox_lib's own wheel (default key Z) if ox_lib runs. - You can replace it. All
ai-*scripts add their items through AI Core, which hands them to the first radial menu that runs: ai-radialmenu, tgiann-radialmenu-target, qb-radialmenu, tgiann-radialmenu, codem-supreme-radialmenu or ox_lib. With another wheel some features are missing (for example qb-radialmenu has no conditions, so an item always shows). See Compatibility.
Known limits
- An item that is unavailable when picked (the player left the vehicle, went off duty) is refused with "That is not available right now".
- qb-radialmenu items have no conditions of their own: they always show.
- tgiann-radialmenu-target's
ClearMenuItemsclears only the calling script's items here (the original clears everyone's).