Installation#
Requirements:
- oxmysql
- MySQL or MariaDB
- A recent FXServer build with OneSync enabled
Steps:
- Copy the
0r-mapeditorfolder into yourresourcesdirectory. - Import
mapeditor.sqlinto your database. - Add the resource to your
server.cfg, after oxmysql:
ensure oxmysql
ensure 0r-mapeditor
- Give yourself permission (see below).
- Start the server and press F7 in game.
Permissions#
Only players with permission can open the editor.
ACE permission (works on every framework):
add_ace group.admin command.mapeditor allow
add_principal identifier.fivem:1234567 group.admin
add_principal identifier.discord:123456789012345678 group.admin
The ace name follows Config.command in config/shared.lua. If you rename the command, the ace becomes command.<yourcommand>. group.admin is also accepted as a fallback.
If useFrameworkAdmin = true in config/server.lua, these are accepted as well:
- ESX:
admin,superadmin,modgroups - QBCore:
admin,godpermissions - Qbox:
group.admin,group.god,qbx.adminaces
Usage#
Open with F7 (players can rebind it in GTA keybind settings) or the /mapeditor command. While the editor is open your character is frozen, invincible, and hunger/thirst is paused.
Basic flow: pick an object from the catalog at the bottom, click in the world to place it, click an object once to select it (move/rotate gizmo), double click to open the quick edit menu. Name your map and hit Save to store it in the database. Changes are also auto-saved shortly after you make them.
Keybinds#
| Key | Action |
|---|---|
| F7 | Toggle editor |
| F | Freecam |
| WASD + Shift/Alt | Camera movement (fast/slow) |
| Right mouse (hold) | Look around |
| Left click | Select object |
| Double left click | Edit menu |
| V | Grab object (follows cursor, scroll for height) |
| G | Snap to ground |
| T | Teleport to object |
| C | Clone |
| Del | Delete |
| M | Multi place |
| B | Marquee select |
| P | Brush paint |
| Ctrl+C / Ctrl+V | Copy / Paste |
| Ctrl+Z / Ctrl+Y | Undo / Redo |
| Q/E | Height while placing |
| Scroll | Rotate while placing |
| Caps | Free cursor |
| X | Cancel / Deselect |
| Esc | Exit editor |
Tools#
- Area Fill: click corners to draw a polygon, fill it with the selected object in a grid or random layout.
- Brush (P): hold to paint the selected object onto the terrain. Density, surface alignment and random rotation are adjustable.
- Marquee (B): box select multiple objects for bulk move, ground, delete, align, array and mirror.
- Eraser: removes original GTA world props (via model hide). Removed props are listed under the Deleted tab and can be restored.
- Area Delete: removes your own placed objects within a radius.
- Lights: place lights with color, range and intensity. Each light can be removed individually.
- Layers: group objects and toggle their visibility per layer.
- Prefabs: save a selection of objects as a reusable set and stamp it anywhere.
- Blips: attach a map blip to any object (name and color). Blips are stored in the database.
Exporting#
The Export window has 5 tabs:
| Format | Contents | Use case |
|---|---|---|
| JSON | Objects, deleted world props, lights | Backup and re-import (merges into current scene) |
| LUA | Ready-to-run script | Drop into any resource as a client_script |
| YMAP | CMapData XML | CodeWalker and similar tools |
| MENYOO | SpoonerPlacements XML | Menyoo compatible |
| CSV | Flat data table | External tooling |
YMAP Publish#
The Publish button on the YMAP tab builds a complete resource on the server under 0r-mapeditor/exports/<mapname>/:
exports/<name>/
├── fxmanifest.lua
├── client.lua
├── <name>.csv
├── <name>.json
└── stream/<name>.ymap
Move that folder into resources and add ensure <name> to your server.cfg. Objects with collision disabled, transparency or hidden state are spawned by the included client script so their properties are kept. If you run multiple ymaps, mind their order in server.cfg or they may not load.
To edit a published map later, paste the contents of <name>.json into the Import JSON box in the Export window. It merges into your current scene.
Configuration#
These files are open (not encrypted) and safe to edit:
config/shared.lua general settings
config/server.lua permissions and webhook
bridge/client.lua framework bridge (client)
bridge/server.lua framework bridge (server, admin check)
locales/locale.lua locale loader
locales/*.json translations
data/props.json object catalog
config/shared.lua#
| Setting | Default | Description |
|---|---|---|
Config.command | 'mapeditor' | Open command. The ace becomes command.<value> |
Config.keybind | 'F7' | Default key, players can rebind |
Config.freezeStatus | true | Pause hunger/thirst while in the editor |
Config.locale | 'en' | Language: 'en', 'tr' or your own |
Config.camera.moveSpeed | 14.0 | Freecam speed |
Config.camera.fastMultiplier | 6.0 | Shift multiplier |
Config.camera.slowMultiplier | 0.25 | Alt multiplier |
Config.camera.mouseSensitivity | 6.0 | Look sensitivity |
Config.camera.fov | 50.0 | Camera field of view |
Config.snap.grid | false | Grid snapping on open |
Config.snap.gridSize | 0.5 | Grid step in meters |
Config.snap.surface | true | Snap to surface |
Config.snap.angle | false | Angle snapping |
Config.snap.angleStep | 15.0 | Angle step in degrees |
Config.snap.snap | false | Snap to nearby objects |
Config.placement.maxRayDistance | 100.0 | Placement distance limit |
Config.placement.ghostAlpha | 150 | Placement ghost transparency |
Config.objectDefaults | - | Default lod/alpha/collision/frozen/visible for new objects |
Config.categories | - | Catalog categories, matched against props.json |
Config.customProps | {} | Add your own streamed props to the catalog |
Config.brush.* | - | Brush defaults: radius, density, spacing, random yaw/tilt, scatter count |
Config.map | - | 2D map image and coordinate bounds |
Adding your own props to the catalog:
Config.customProps = {
{ model = 'my_prop_01', label = 'My Prop', category = 'misc' },
{ model = 'my_door_01', label = 'Custom Door', category = 'urban' },
}
config/server.lua#
| Setting | Default | Description |
|---|---|---|
permission.ace | command.<command> | Main ace |
permission.aceFallback | 'group.admin' | Fallback ace |
permission.useFrameworkAdmin | true | Also accept framework admin groups |
permission.ownerOnly | false | If true, players can only overwrite their own maps |
webhook | '' | Discord webhook URL, logs every editor action when set |
webhookName | '0r-mapeditor' | Webhook display name |
Adding a language#
- Copy
locales/en.jsonto for examplelocales/de.jsonand translate it. - Set
Config.locale = 'de'inconfig/shared.lua. - Missing keys fall back to English automatically.
bridge files#
Framework detection and the admin check live here. If you run a custom framework or a different admin system, edit Bridge.IsAdmin in bridge/server.lua.
data/props.json#
The catalog data with 13,000+ objects. You can edit it directly for bulk changes, but for a handful of additions prefer Config.customProps so updates do not overwrite your work.
Troubleshooting#
The editor does not open. Check your permission setup. The console prints [0r-mapeditor] framework: ... on start, make sure it detected the right framework.
A published ymap does not show in game. Make sure ensure <mapname> is in your server.cfg and, if you run several ymaps, that their load order is correct.
Objects are not being saved. Check that mapeditor.sql was imported and that oxmysql is connected. Look for oxmysql errors in the console.
Does the eraser remove nearby copies of the same prop? No. Removal points are stored with 0.25m precision, only the prop you clicked is hidden.
Do lights, objects and blips disappear when I close the editor? No, they stay as long as the map is loaded. After a resource restart, load the map again.
Do collision-disabled objects work in a published ymap? Yes. Those objects are moved to the script side during publish and keep their properties.