Security HUD
System Watchdog
×
Threads Scanned
-- / --
SYS. LOAD --%
AI SHIELD ACTIVE
DMCA Policy
×

📋 DMCA Compliance

This platform and community fully complies with the Digital Millennium Copyright Act (DMCA) and international copyright laws. We take all copyright protection seriously.

🛡️ Copyright Protection

If you believe a posted item belongs to you or violates your copyright, you may file a DMCA takedown request through our official channels. Upon receiving a valid claim, the infringing content will be removed within 24 hours.

What's new
RavenAC

Question QbCore cardealer selling more than one class add?

MaxHero

Gold Elite
Joined
Jul 10, 2021
Messages
209
Solutions
5
Reaction score
293
Points
316
Location
Türkiye
İ have below client.lua cardealer script part i need add more than one ['Class'] how can i add it ?
i mean i have only 'custom' Class ............ i want more than one class ... 'custom'+ 'coupe' +'suv' etc..

"function IsModelASellVehicle(Entity)
for k, v in pairs(QBCore.Shared.HashVehicles) do
if k == GetEntityModel(Entity) and v['Class'] == 'custom' then
return true
end
end
return false
end"
 

DiabloX9

Gold Elite
Joined
Dec 10, 2021
Messages
74
Reaction score
3,611
Points
311
Location
LS
Website
diablox9.tebex.io
You need to edit 2 files :
-> qb-vehicleshop/config.lua

add a class here :

1655555130788.png


"test" is the variable and "GAY CARS" will be what the player will see IG.


Once it's done, let's go to the second file :
-> qb-core/shared/vehicles.lua

Add or edit the class of the car :

1655555244752.png

['rs7c8'] is the variable name, it's the name you use when you spawn it with "/car xxx".
You need to set the same for : 'model' and 'hash'.
'Name' : Visual name for player
'Brand' : Visual name for player
'Category' : Variable name we gave to the category just before
'shop' : Where it should be available to buy (PDM is the default place).

Results :
20220618142133_1.jpg

20220618142144_1.jpg
 
Top