mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-29 08:01:24 +00:00
fix(es_extended/server/classes/vehicle): properly object to new vehicle plate
This commit is contained in:
@@ -147,7 +147,14 @@ Core.vehicleClass = {
|
||||
|
||||
Entity(xVehicle.entity).state:set("plate", plate, false)
|
||||
SetVehicleNumberPlateText(xVehicle.entity, plate)
|
||||
|
||||
local oldPlate = xVehicle.plate
|
||||
xVehicle.plate = plate
|
||||
Core.vehicles[plate] = table.clone(xVehicle)
|
||||
Core.vehicles[self.plate] = nil
|
||||
|
||||
TriggerEvent("esx:changedExtendedVehiclePlate", xVehicle.plate, oldPlate)
|
||||
Wait(0)
|
||||
|
||||
return true
|
||||
end,
|
||||
|
||||
Reference in New Issue
Block a user