All scripts
Every ai-* script that comes with AI Core, how the categories work, and where each script's page is.
AI Core comes with around forty ai-* scripts. Together they make a full roleplay server: characters, money, an inventory, a HUD, vehicles, jobs, police, crime and housing. You do not have to use all of them.
How the scripts fit together
- Each script is its own resource. It has its own folder in
resources/[ai]/and its ownensureline inserver.cfg. Remove the line and the script is gone. - Every setting is in the admin panel. Each script adds its own tabs to the admin panel (press F10 in the game). You never edit a config file.
- Scripts talk through AI Core. When a robbery gives an item, it asks AI Core, and AI Core hands the item to the inventory you run. The robbery script does not know whether that is ai-inventory or another inventory. This is why you can replace almost any
ai-*script with a third-party script of the same kind (see Compatibility). - Third-party scripts keep working. Many
ai-*scripts also answer the exports of the well-known script they replace. For example, ai-inventory answersexports.ox_inventory:AddItem(...), so a script written for ox_inventory runs unchanged. Each script's page lists what it stands in for.
How the categories work
The scripts are grouped by what they are for. Each category has an overview page, and each script has its own folder with two pages:
- The script page is for server owners: what the script does in the game, how to install it, every panel setting, its commands and keys, and which third-party scripts it works with.
- The developer page is for people writing scripts: its exports, events and state bags, with types and examples in TypeScript and Lua.
| Category | What is in it |
|---|---|
| Essentials | The framework and the scripts every server needs: database, shared UI, loading screen, clothing, inventory, HUD, chat, voice, radial menu, target eye, scoreboard, time and weather. |
| Vehicles | Owned vehicles, keys, fuel, garages, shops, used car lots, rental, mechanics and emergency lights. |
| Jobs and services | Work routes, police, police alerts, prison, death and EMS, banking, boss menus and the city hall. |
| Crime and racing | Robberies, drugs, pawnshops, scrapyards and street races. |
| World and tools | Housing, door locks, many small features, sleeping bodies, character size and admin tools. |
Every script
| Script | What it does |
|---|---|
| ai-core | The framework: players, characters and the character screen, money, jobs and gangs, permissions, the admin panel, and the ESX / QBCore / Qbox / vRP bridge. |
| ai-mysql | The database engine for third-party scripts. Stands in for oxmysql, mysql-async and ghmattimysql. |
| ai-lib | The shared player UI (notifications, progress bar, prompts, menus, minigames) and the AI Core helpers for Lua and JavaScript resources. |
| ai-loading | The loading screen with your server name, a background, the loading progress and tips. |
| ai-appearance | Character creator, clothing stores and barbers. |
| ai-inventory | Grid inventory with drops, stashes, trunks, shops, crafting and weapons. Answers the ox_inventory and qb-inventory APIs. |
| ai-hud | The HUD and the needs: health, hunger, thirst, stress, a speedometer and key hints. |
| ai-chat | Chat with channels and command suggestions. Stands in for FiveM's chat. |
| ai-voice | Proximity voice, radio and phone calls. Stands in for pma-voice. |
| ai-radialmenu | The radial menu on F3, with the items every script adds. |
| ai-target | The target eye for interaction points. Answers the ox_target API. |
| ai-scoreboard | Players online and on-duty counts per job. |
| ai-weathersync | Time and weather the same for everyone, with weather regions. Stands in for qb-weathersync. |
| ai-vehicles | Owned vehicles of characters, jobs and gangs. |
| ai-vehiclekeys | Vehicle keys, locking, lockpicking and hotwiring. |
| ai-fuel | Fuel use and gas stations. |
| ai-garages | Garages, job and gang fleets, impound lots. |
| ai-vehicleshop | Vehicle shops with a live preview. |
| ai-vehiclesales | Used car lots: players list their vehicles, others test drive and buy. |
| ai-rental | Vehicle rental. |
| ai-mechanic | Repair, tuning with a preview, car washes. |
| ai-sirens | Emergency lights, siren tones, lightbars. |
| ai-jobs | Work routes: taxi, bus, trucker, garbage, tow and more. |
| ai-police | Police menu, cuffs, fines, prison and impound. |
| ai-policealert | Police alert cards. |
| ai-prison | Jail sentences, prison work, escapes. |
| ai-death | Death, hospitals, EMS revive. |
| ai-banking | Banks, ATMs, society accounts. |
| ai-management | Boss menu. |
| ai-cityhall | Job center and documents. |
| ai-robberies | Stores, banks, jewelry, houses, armored truck. |
| ai-drugs | Street sales and weed plants. |
| ai-pawnshop | Pawnshops and scrapyards. |
| ai-streetraces | Street races to a waypoint with a buy-in. |
| ai-properties | Houses and apartments. |
| ai-doorlock | Door locks. |
| ai-smallresources | Seatbelt, cruise control, crouch, sitting, carrying and many small features. |
| ai-exitsleeping | Logged-out players stay as sleeping bodies. |
| ai-pedscale | Character height and width. |
| ai-admin | Noclip, teleports, revive, vehicles, quick menu. |
Default keys
Each player can change every key in GTA's own settings (Settings > Key Bindings > FiveM). The owner changes the starting key for everyone in the admin panel (Keybinds tab); a player who already changed a key keeps their own.
| Key | Action | Script |
|---|---|---|
| F10 | Admin panel (admins only) | ai-core |
| F9 | Admin quick menu (admins only) | ai-admin |
| F3 | Radial menu | ai-radialmenu |
| F2 | Inventory | ai-inventory |
| TAB | Quick slots bar | ai-inventory |
| 1 to 5 | Use the item in that quick slot | ai-inventory |
| R | Reload the weapon | ai-inventory |
| T | Chat | ai-chat |
| F6 | Police menu (on duty) | ai-police |
| E | Interact with the prompt on screen | ai-lib |
| Backspace | Cancel the running action | ai-lib |
| U | Lock or unlock the vehicle | ai-vehiclekeys |
| M | Engine on / off | ai-vehiclekeys |
| K | Seatbelt | ai-smallresources |
| F11 | Voice range | ai-voice |
| Left Alt | Talk on the radio | ai-voice |
| Home | Scoreboard | ai-scoreboard |
Each script's page lists all of its keys.