AdvancedParking v4.11.1 - Persistent vehicles! [ESX] [QB] [QBOX] [OX] [Standalone]

What is it and what does it do exactly?

If a player enters a vehicle, it will be registered in the database as a saved vehicle. The vehicle
will always stay at the last location where it has been left by a player. If it despawns while
players are too far away from it or after a server restart, the script will respawn the vehicle on
server side as soon as a player gets close enough again. This also means no more “despawns” when
looking away for a second.

All vehicle modifications and statuses are saved (check saved values for more
information) and will be reapplied upon respawning.

Vehicles that have been saved are completely dynamic. You can push a saved vehicle with a bulldozer
and it will update accordingly.

:video_camera: Showcase Video

Requirements

Code is accessible ~75% accessible
Subscription-based No
Lines (approximately) ~3200
Requirements Check requirements above
Support Yes

:floppy_disk: :shopping_cart: Where can I get this?

This script is available for 17.50€ (plus sales tax) at:
https://kiminazes-script-gems.tebex.io/package/4287488

You are getting access to the current live and experimental version.

:book: Documentation

https://docs.kiminaze.de/scripts/advancedparking

:question: Support

https://discord.kiminaze.de

:clipboard: Features

  • All vehicles a player has entered will be saved.
    • Configurable vehicle class, model and plate blacklist.
  • Vehicles will respawn automatically when players get close and the vehicle isn’t there.
  • Vehicles will respawn after a server restart.
  • Vehicles that have been saved are completely dynamic. They can be moved and take damage.
  • Vehicle spawning happens on server side.
  • Attached trailers will be saved automatically.
  • Option to save only player owned vehicles (requires ESX or QB).
  • Cleanup function takes care of vehicles that haven’t been updated.
    • Configurable time threshold.
    • Option to send cleaned up vehicles to the player garage (requires ESX or QB).
  • Non-networked (or client side only) vehicles will be ignored.
  • Can be restarted any time.
  • Delete function that will delete any vehicle where a player is not close enough every X
    minutes (turned off by default). This is only meant for servers that have an over-abundance of
    (modded) vehicles where it could have a negative impact on performance (e.g. 200+ players + NPC
    vehicles).
  • Admin command for deleting all vehicles from the database table.
  • Exports for receiving the position of vehicles from server and client side.

Saved values

While this script aims to save all variables of a vehicle, some of them can not yet be updated on
server side and will only be updated when entering/leaving the vehicle (or when using the included
UpdateVehicle export).

  • Position and rotation
  • Status:
    • Entity, body, engine and petrol tank health
    • Dirt Level
    • Fuel Level (includes compatibility with “LegacyFuel”)
    • Door lock status
    • Burst/flat tires
    • Missing doors
    • Broken windows
  • Tuning:
    • Number plate text
    • Modifications from 0-49 (except 17, 19 and 21 (possibly HSW mods that aren’t in the game yet))
      • Visual and performance mods
    • Colors
      • Primary and secondary
      • Custom primary and secondary (RGB)
      • Pearlescent
      • Interior
      • Dashboard
      • Tiresmoke
      • Window tint
    • Lights
      • Xenon color
      • Neonlights color
      • Enabled neons
    • Extras
    • Wheels
      • Type
      • Custom
      • Bulletproof
      • Color
      • Drift Tires
    • Livery (from mods, extra livery and roof livery)
  • Extra values:
    • engine on/off
    • landing gear state
    • vtol position
    • boat anchor state
    • convertible roof state
    • stub wings state
  • Entity state bags

:fire: Performance

  • Client Side:
    • idle: 0.00ms
    • inside vehicle: 0.01ms
  • Server Side:
    • idle: 0.00ms
    • updating vehicles: 0.00-0.50ms (dependent on how many players and vehicles are present) (will
      receive another big update through next experimental version to improve numbers significantly!)

:clipboard: Patchnotes

https://github.com/Kiminaze/version_history/blob/main/AdvancedParking.json

42 Likes

Any preview? :thinking:

Hi! you can see other players parked vehicles?

It save all vehicles you drive or only your owned vehicles?

It does delete vehicle if there no people close to vehicle?

With how many vehicles you test it?

What happend if there are more than 125 limit vehicles of gta spawned?

Update:
Fixed a small oopsie on server side.

If you already bought the script, you can access this update via the same link that was already provided to you.

Not right now. Was thinking about a small video. We’ll see… maybe later this week :smiley:

Yes, you can see all vehicles that have been saved. So pretty much every vehicle that had a player in it once. Doesn’t matter if owned or not, if job vehicle or not.

No, it does not delete vehicles if no one is close to it. Unless GTA itself decides to delete it automatically. I do not do that.

On our liveserver it ran perfectly with ~20-30 players and ~100 vehicles.
After spawning, I unload the models immediately, so there should not be any problems when above.

If you encounter any problems with the script, feel free to tell me! I will fix it asap :slight_smile:

there is a limit of 128 spawned vehicles at the same time (it’s a native limit of gta) if there are more, the next vehicle don’t spawn.

Try to spawn more than that and test it. i don’t know if with onesync infinity you can bypass that

With this: [Release][OneSync] Enc0ded Persistent Vehicles

that problem happends and i’m pretty sure that you use the same system (Retrieve info of all vehicles bu server with the onesync implemented native)

if your script can spawn more vehicles and vehicles spawn correctly with no random boats on city like the enc0ded script, i’ll buy it.

1 Like

Okay, I’ll push an update later today to fix compatibility with another script and test this as well. I’ll let you know what I find out :slight_smile:

1 Like

Have you A Video

1 Like

If this is possible, i’ll buy it too

1 Like

Vehicle spawns after a bit of time, but then when you use another vehicle. The old parked one flashes / Flickers where it’s parked.

No, but will probably come during this week. I don’t have a lot of time to record :smiley:

Could you make a video of that? Never seen that happening. :confused:

1 Like

Are you really using MySQL for a script like that? Servers with more than 100 players will explote the DB

If you get out the other car, then the old saved one spawns.

Have you tried it? I think my main concern would be network traffic, not database performance. But nonetheless, future releases will be more performant.

@Minty2 Well that is interesting. Are you using OneSync Infinity? How old is your server artifact version? How many players were online at that time?

Hi, So doesn’t matter which car is spawned. It causes old parked cars to flicker. Is just me on the server, OneSync Enabled and 3404, Brand new FiveM server.

Damage is not saved. Even with a very damaged car. We tested it with two people, and sometimes some vehicles are not charged. No bug reports. We use the Artifact 3404 and One Sync Infinity.

1 Like

What type of damage are you talking about?

I save those 3:
health
bodyHealth
engineHealth
petrolTankHealth

If you are talking about the visual damage:
I can’t save those. Noone can. Noone even knows how to do that. Unless you know a script or mod which already does that and allows access to its source code. If you point me to it I will gladly use that as well!

I mean health, bodyHealth, engineHealth and petrolTankHealth. As soon as you get into the vehicle, everything is fine with the vehicle.

Finally! Here is a new update for you all :slight_smile:

If you already bought the script, you can access it from the same link that was already sent to you.

@mikastro @Flobbah There should now not be any problem with this. A client is now restricted to 32 vehicles. If you decide to buy it, then let me know if you encounter any issues!

@Minty2 I could not reproduce this issue at all. If you could try it with the new update and let me know if it still happens. Also did it happen with modded vehicles only? Or does it also happen with Vanilla vehicles?

@oidetschesn This should all be saved. Do you have reproduction steps for me?

1 Like