its working
btw, how do I connect the images to cars
look for server prints and error.
looks like a money issue from server callback.
your using ESX 1.1?
btw i pushed an update to be able use a custom URL from database
Config.CustomImg = false ā if true your Config.CustomImgColumn IMAGE url will be used for each vehicles else, the imgs/uploads/MODEL.jpg
Config.CustomImgColumn = āimglinkā ā db column name
Changes: client.lua,script.js
What do you mean with esx 1.1, and do you recommend for economy/money script
Hello many of my addon cars are not showing at the shop but they use to work fine with my old vehicle shop, does anyone now something about this?
addon cars work fine
unless you give me some specific vehicle model (link or any download to test on)
this is the only thing i can help you.
the shop relies with your vehicle model name from vehicles.model (database column)
if your model name has special char or space or Uppercase it wont work.
Multiple car shops are possible, right? So I could, for example, sell trucks & SUVs at another location other than PDM? I could make a high-end sportscar dealership, selling only the zoom zoom cars. Maybe use the Benefactor MLO and sell only Benefactor and Gallavanter models.
I assume that weād change the table for the shop for the cars we want to sell elsewhere. but what if we sell a car at two locations?
I was thinking about used cars, since they can be a lower price alternative for new players to the city.
Can a car that has been sold to the main dealership be sold as a āused car?ā
A config setting indicating that we have a used lot that if set to yes, then instead of deleting the car, that car can be placed in a table and sold at another lot.
A used car lot could be done, with the quick pick feature only. Just walk up, buy the car, drive it away. I plan to use the Mosely MLO and set up a used car lot and auto repair facility.
Just some ideas. This is a great resource!
Thank you
Yes multiple carshop can be configure for multi locations
Using the shop table config yes. This is preferable.
Multiple or duplicate models are possbile for ea shop.
You can use the shop table and display table for multiple location.
And about used cars. I am thinking to add soon a player owned for sale vehicles.
Or your idea about storing a sell vehicle to sale it with a lower price is a good too.
Maybe ill add both idea.
I just figure if the player sells the vehicle to the dealer, the dealer can place it for resale. Kind of how it works in the real world. Just finding a way to implement it, thatās your job.
Hey Renzu,
idk why but the selling function is not working for me.
IĀ“m using your garagescript aswell as popui.
At Line 118:
r = Database(āSELECT * FROM owned_vehicles WHERE UPPER(plate) = @plate and owner = @ownerā, {[ā@plateā] = plate:upper(), [ā@ownerā] = xPlayer.identifier},xPlayer.source,āfetchā)
this line of code gives me an nil value, i just used print(plate) to see what value it dropsā¦ but there is none.
I did not change anything about the vehicleshop script yet.
I just bought a car, parked it, spawned it and tried to sell it.
Do you know whats going on ?
I tried to do the db call without the UPPER and :upper() addition. It does something atleast, it tells me that IĀ“m not the owner of the car but still gives me a nil value for the plateā¦
Edit: IĀ“m using the newest version of your scripts as well
There is also a bug with the PlateSpace function:
The space is not removeable and changing the plate numbers and letters is weird
The client and server.lua is calling Config.PlateSpace and the .cfg uses PlateUseSpace = true.
I changed it already but there is no difference in the script behavior
server.lua 150:
if not Config.PlateSpace then
total = 8 - plate:len()
else
total = 7 - plate:len()
end
if total ~= 0 then
Those ātotalā doent care about the config file. The Script alway tries to get the 8 chars. I changed the 8 to a 4 andā¦ wellā¦ it worked somehow. The script is still trying to have 3 letters in front and fills the rest with numbers. And it doesnĀ“t helped with the selling thing.
Plate space workes in some kindā¦ The plate has the 3 letters, a Number and then a space xD
like āABC1 234ā (if youĀ“re using 8 letters if you use 5 like me its like (ABC1 2))
local vehicle = GetVehiclePedIsIn(GetPlayerPed(source))
local plate = GetVehicleNumberPlateText(vehicle)
The Vehicle Selling Function is Server based to avoid Exploits.
Your Screenshot shows its a different config.
its definitely not this vehicle shop
Vehicle Shop Plate system use 7 CHAR with Space or 8 CHAR without space.
Yea i literally just realized that with the second config iĀ“m so sorry haha iĀ“m going back into the game and test everything ^^
Abouth the Upgrade, do you recommend any ? The server runs with 4291
im not sure i know 4k + supports it ,
are you in game build Tuner?
yes iĀ“m launching with gamebuild 2372
Thats why, some fxserver build have some issue in vehicle server native. Specially the plate getter.
Im sure its fix in more latest fx builds.
I havent try upgradingā¦ my current fx server version in local does have the issue in tuner build tooā¦
Try the recommended ver.
Okay, so far so good. It works with artifacts 4478 .
anoother thingā¦ server.lua 131:
xPlayer.showNotification(āVehicle has been Sold for ^g āā¦priceā¦āā,1,0,110)
the ā^gā isnĀ“t working like coloring the text in green.
IĀ“m using ~g~ ā¦ ~s~ and it works fine.
Not sure im not good with colors in notifs.
You can change all notis to your custom notifcation ex. Mythic notify
can u run the car dealer and if yes wht do u put in to activate it because i cant find anything about it so just want to find out thanks