Browse docs
Server: GetVehicleCondition(plate)
Reference for Server: GetVehicleCondition(plate) in mechanicjob.
This page documents supported public integration calls and usage examples. It does not expose or reproduce the resource's internal implementation.
Server Exports
All Advanced Pricing and Billing exports return a result table:
{
success = true,
data = {}
}
Rejected requests return success = false and a stable error code. Player identity, mechanic job, grade, permissions, vehicle distance, configured limits, quote state, invoice ownership, and monetary values are always resolved or validated on the server.
GetVehicleCondition(plate)
- Purpose: Returns the saved mileage and all diagnostic wear values for a vehicle.
- Arguments:
plate(string) - vehicle plate text. Required.
- Returns:
table | nil- a table containingplate,mileage, andwear, ornilfor invalid input or a database failure.
server.lua
local condition = exports["sky_mechanicjob"]:GetVehicleCondition("ABC123")
if condition then
print(("Mileage: %s, engine oil: %.1f%%"):format(
condition.mileage,
condition.wear.engine_oil
))
end