Jota Dev Welcome Car
Here you can find documentation on how to install our store's welcome car system.

How to start the script for its correct operation:
Put in your server.cfg
# JotaDev WelcomeCar
ensure jc_coche_bienvenidaInsert SQL into your database and configure your framework:
CREATE TABLE IF NOT EXISTS welcome_cars (
identifier VARCHAR(50) PRIMARY KEY,
claimed BOOLEAN DEFAULT FALSE
);Config = {}
Config.Framework = 'esx' -- Ingrese "esx" para ESX o "qb" para QbCore
Config.NPC = {
model = "mp_m_waremech_01",
coords = vector3(225.51771, -857.096, 30.106513),
heading = 157.94825
}
Config.SpawnCar = {
coords = vector3(229.79135, -852.1683, 29.951473),
heading = 245.43571
}
Config.Garages = 'default' -- 'default' o 'editable', en caso de que quieres editar, Editable/Server/SMain.lua
Config.MoledoCoche = 'comet6'
Config.VehicleInfo = {
nombre = "Comet 6 Estilo y Potencia",
descripcion = "El gobierno decide aportar un vehiculo para comenzar su vida en la ciudad.",
imagen = "https://i.fmfile.com/2tAOsptSJW1WZ3XCzhHdQ/welcome_car_comet.png",
prestaciones = {
velocidad = "240 km/h",
aceleracion = "Media",
consumo = "Bajo"
},
nombre_server = {
nombre = "Jota Dev Roleplay",
informacion = "Prepárate para la mejor inmersión en la ciudad"
}
}
Config.DiscordWebhook = '' -- Insete tu discord Webhook
Config = {}
Config.Framework = 'qb' -- Ingrese "esx" para ESX o "qb" para QbCore
Config.NPC = {
model = "mp_m_waremech_01",
coords = vector3(225.51771, -857.096, 30.106513),
heading = 157.94825
}
Config.SpawnCar = {
coords = vector3(229.79135, -852.1683, 29.951473),
heading = 245.43571
}
Config.Garages = 'default' -- 'default' o 'editable', en caso de que quieres editar, Editable/Server/SMain.lua
Config.MoledoCoche = 'comet6'
Config.VehicleInfo = {
nombre = "Comet 6 Estilo y Potencia",
descripcion = "El gobierno decide aportar un vehiculo para comenzar su vida en la ciudad.",
imagen = "https://i.fmfile.com/2tAOsptSJW1WZ3XCzhHdQ/welcome_car_comet.png",
prestaciones = {
velocidad = "240 km/h",
aceleracion = "Media",
consumo = "Bajo"
},
nombre_server = {
nombre = "Jota Dev Roleplay",
informacion = "Prepárate para la mejor inmersión en la ciudad"
}
}
Config.DiscordWebhook = '' -- Insete tu discord Webhook
If you use an external garage, edit it in jc_coche_bienvenida/Editable/Server/SMain.lua
Config.Garages = 'editable' -- 'default' o 'editable', en caso de que quieres editar, Editable/Server/SMain.luafunction InsertVehicleToGarage(identifier, model, plate, defaultMods, framework)
-- EJEMPLO OKOKGARAJE
local vehicleData = json.encode(defaultMods)
local sharedWith = json.encode({})
local query = [[
INSERT INTO owned_vehicles (
owner, plate, vehicle, `stored`, type, parking, doorcondition, windowcondition, tyrecondition,
favourite, impoundTime, location, reason, sharedwith, vehiclename
) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
]]
MySQL.insert(query, {
identifier,
plate,
vehicleData,
0,
'car',
'public',
nil, nil, nil,
0,
nil, nil, nil,
sharedWith,
model
}, function(id)
print("ID:", id)
end)
end
Last updated