Garage Scripts (jg-advancedgarages)

How MonoAdmin works with jg-advancedgarages v3: its vehicles, garages and impounds, and putting deleted cars back in their garage.

A garage script decides where a player’s car is: in a garage, out in the world or in an impound lot. On a server that runs jg-advancedgarages, that script keeps this record in its own fields, and ignores the garage fields your framework has. So MonoAdmin reads and writes jg’s record instead. This page explains what that changes on the Vehicles page, how an impound works with jg, what happens when a car jg took out is deleted, and what is not covered.

Which Garage Scripts Are Supported

Script Version ESX QBCore Qbox
jg-advancedgarages v3 (built against 3.2.10) Yes Yes Yes
jg-advancedgarages v4 Shown only Shown only Shown only

No other garage script is recognised. Without jg, MonoAdmin uses your framework’s own garage data, as described in Characters and Owned Vehicles.

jg v4 keeps its garages differently and is not supported yet. MonoAdmin still detects it and shows its vehicles, but it changes nothing while v4 runs.

The garage support works wherever the Vehicles page does, so it needs ESX, QBCore or Qbox with oxmysql. See Requirements.

How MonoAdmin Detects It

The resource looks for a started jg-advancedgarages and reads the version from its manifest, which jg writes as v3.2.10. Detection runs again about a second after jg starts or stops, so you do not need to restart MonoAdmin. You can see the result in three places:

  • the Integrations: line of monoadmin status, which ends with garage jg-advancedgarages v3.2.10 or garage none,
  • the guided setup’s What We Found on Your Server screen, in the Garage script row (see The Guided Setup),
  • Settings > Server Link, in the Garage script row.
What you see What it means
The script and its version. The setup screen adds “Vehicles use the garages and impound lots of jg-advancedgarages, with a reason and a Retrieval Cost on impounds. Deleting one of its cars puts it back in its garage.” jg v3 runs and is supported.
A Not supported yet badge in Server Link, and “{script} is not supported yet. MonoAdmin supports v3; its vehicles are shown but not changed.” jg runs, but in another major version, such as v4.
“None found. Works with jg-advancedgarages.” in Server Link, “No garage script found, so vehicles use your framework’s own garage data.” in the setup jg is not started. Vehicles use your framework’s own garage data.

What the Vehicles Page Shows

With jg v3 running, the Vehicles page and a player’s Vehicles tab read jg’s own record on every framework, so the list matches what players see in jg’s garages.

Where you see it What changes with jg
Where Stored means the car is in its garage and not impounded. Impounded shows the lot. Out is a car taken out and not put back.
Under the plate The Nickname the owner gave the car in jg.
Owner A car that belongs to a job or a gang reads Job: police or Gang: ballas, because jg files it under the job or gang instead of a character. Hover it for “This vehicle belongs to the job, not to one player.”
Details Retrieval Cost (what the owner pays to take the car out of the impound) in place of Depot Fee, on ESX too. Also the Nickname, the Gang, the Impound Reason and Impounded By of an impounded car.

A car impounded from MonoAdmin shows Server staff as Impounded By. No staff name or account is sent to your game server.

Changing Vehicles

The row menu is the one described in Characters and Owned Vehicles. With jg these things differ.

Choosing a Garage or an Impound Lot

Change Garage, Impound and Release show a searchable list of the places jg knows instead of a text box, and each place says what it takes: Cars, Boats or Aircraft. Garages are offered for Garage, impound lots for Impound Lot. If MonoAdmin cannot tell the lots from the garages, every place is offered for an impound and your game server has the last word.

If the list cannot be read, the dialog falls back to a box where you type the name exactly as jg writes it, for example Benny's Originals. The list is read from jg and kept for about a minute, so a garage you just added can take a moment to appear.

Change Garage

Changes the garage, and whether the car counts as stored there. It is refused in two cases:

  • The car is impounded. Release it first. The row menu does not offer Change Garage for an impounded car.
  • The car is out in the world. Marking a car stored or not stored, and impounding or releasing it, are refused while the car exists in the world, because jg would write its own state back and undo your change. Put the car away first.

Impound

Impound moves a car to one of jg’s impound lots. You choose:

  • the Impound Lot,
  • a Reason (optional), up to 128 characters, which the owner sees in jg’s garage,
  • a Retrieval Cost, which is what the owner pays at the impound to take the car out. 0 is free. This is set on ESX too.

The owner can then take the car out at the lot, for the retrieval cost, the way they would after any jg impound. A car that is already impounded is refused.

Release

Release takes a car out of its impound lot and stores it, with no retrieval cost. You can choose a garage, or leave it empty. Empty sends the car back to the garage it was impounded from, which the dialog names when it is known. If it is not known, the dialog asks you to choose one.

Deleting Cars in the World

When a car that jg took out is deleted, jg does not notice. The owner then pays jg’s return fee for a car that no longer exists, or is told it is already out. So while jg v3 runs, MonoAdmin gives owned cars back to their garage when it deletes them, the same as jg’s own /vreturn: the car is put back in its garage and the owner pays no return fee.

This applies to every place MonoAdmin deletes a car in the world:

The confirmation says so: “Owned vehicles go back to their garage.” Know these points:

  • Only owned vehicles are put back, whether they belong to a player, a job or a gang. A car a staff member spawned is simply deleted.
  • An impounded car stays impounded.
  • Damage and tuning done since the car was last stored is lost, as with any delete.
  • The delete is never blocked. If jg or your database cannot be reached, the car is still deleted and the console prints a warning, and the owner may be charged the fee.
  • On Qbox, MonoAdmin also stops qbx_core from spawning a deleted owned car again.
  • Deleting a vehicle from the owner’s vehicles on the Vehicles page also tells jg the car is no longer out.

While jg Runs

MonoAdmin never touches the framework’s own garage fields while jg v3 runs: stored state, garage, impound and depot fee are read and written in jg’s record only. If you remove jg later, its leftover data is ignored and the Vehicles page reads your framework’s own garage data again.

Messages You May See

When your game server refuses a change, the panel says why:

Message Why What to do
The vehicle is impounded. Release it first. You tried to change, or impound again, a car that is in an impound lot. Release it, then change it.
The vehicle is out in the world right now. Put it in a garage in game, or delete it from the world, first. The car is out, and jg would undo the change. Have the owner put it away, or delete it from Server Entities.
That is not one of the garages on your server. The garage you chose is not one of jg’s garages (or is an impound lot). Pick one from the list.
That is not one of the impound lots on your server. The lot you chose is not one of jg’s impound lots (or is a garage). Pick one from the list.
The vehicle has no garage to go back to. Choose one. A release with no garage, and jg has no record of where it came from. Choose a garage.
Your server runs a version of its garage script MonoAdmin does not support yet, so its vehicles cannot be changed here. jg runs in another major version. Use jg v3, or change vehicles in game.
The garage script runs, but its columns are missing from the vehicles table. Run its install SQL, then try again. jg is started, but its install SQL was never run on your database. Run jg’s install SQL, then try again.

Limits

  • jg v4 is detected, and its vehicles are shown, but they are not changed from MonoAdmin.
  • Fake plates. A car that wears a fake plate from a script such as brazzers-fakeplates is not matched to its owner, so deleting it does not return it to its garage.
  • Clear Area in the in-game menu does not park cars. Only the deletes listed above do.
  • QBCore plates are not unique. If two owned vehicles share a plate, deleting a car with that plate puts both back, as jg does.
  • If jg runs but its install SQL was never run, vehicles keep reading your framework’s garage data and changes are refused with the reason above.

For the rest of the Vehicles page, see Characters and Owned Vehicles. For the other scripts MonoAdmin works with, see Supported Frameworks.