Skip to content

Installation

Dependencies, database, server.cfg order, and a quick test.

Installation#

Requirements:

  • oxmysql
  • MySQL or MariaDB
  • A recent FXServer build with OneSync enabled

Steps:

  1. Copy the 0r-mapeditor folder into your resources directory.
  2. Import mapeditor.sql into your database.
  3. Add the resource to your server.cfg, after oxmysql:
cfg
ensure oxmysql
ensure 0r-mapeditor
  1. Give yourself permission (see below).
  2. Start the server and press F7 in game.

Permissions#

Only players with permission can open the editor.

ACE permission (works on every framework):

cfg
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, mod groups
  • QBCore: admin, god permissions
  • Qbox: group.admin, group.god, qbx.admin aces

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#

KeyAction
F7Toggle editor
FFreecam
WASD + Shift/AltCamera movement (fast/slow)
Right mouse (hold)Look around
Left clickSelect object
Double left clickEdit menu
VGrab object (follows cursor, scroll for height)
GSnap to ground
TTeleport to object
CClone
DelDelete
MMulti place
BMarquee select
PBrush paint
Ctrl+C / Ctrl+VCopy / Paste
Ctrl+Z / Ctrl+YUndo / Redo
Q/EHeight while placing
ScrollRotate while placing
CapsFree cursor
XCancel / Deselect
EscExit 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:

FormatContentsUse case
JSONObjects, deleted world props, lightsBackup and re-import (merges into current scene)
LUAReady-to-run scriptDrop into any resource as a client_script
YMAPCMapData XMLCodeWalker and similar tools
MENYOOSpoonerPlacements XMLMenyoo compatible
CSVFlat data tableExternal tooling

YMAP Publish#

The Publish button on the YMAP tab builds a complete resource on the server under 0r-mapeditor/exports/<mapname>/:

text
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:

text
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#

SettingDefaultDescription
Config.command'mapeditor'Open command. The ace becomes command.<value>
Config.keybind'F7'Default key, players can rebind
Config.freezeStatustruePause hunger/thirst while in the editor
Config.locale'en'Language: 'en', 'tr' or your own
Config.camera.moveSpeed14.0Freecam speed
Config.camera.fastMultiplier6.0Shift multiplier
Config.camera.slowMultiplier0.25Alt multiplier
Config.camera.mouseSensitivity6.0Look sensitivity
Config.camera.fov50.0Camera field of view
Config.snap.gridfalseGrid snapping on open
Config.snap.gridSize0.5Grid step in meters
Config.snap.surfacetrueSnap to surface
Config.snap.anglefalseAngle snapping
Config.snap.angleStep15.0Angle step in degrees
Config.snap.snapfalseSnap to nearby objects
Config.placement.maxRayDistance100.0Placement distance limit
Config.placement.ghostAlpha150Placement 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:

lua
Config.customProps = {
    { model = 'my_prop_01', label = 'My Prop', category = 'misc' },
    { model = 'my_door_01', label = 'Custom Door', category = 'urban' },
}

config/server.lua#

SettingDefaultDescription
permission.acecommand.<command>Main ace
permission.aceFallback'group.admin'Fallback ace
permission.useFrameworkAdmintrueAlso accept framework admin groups
permission.ownerOnlyfalseIf 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#

  1. Copy locales/en.json to for example locales/de.json and translate it.
  2. Set Config.locale = 'de' in config/shared.lua.
  3. 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.