Master Mind Development
DiscordTebexGithub
  • ๐Ÿ’ฐPaid Release
    • ๐Ÿ“ฆAirdrop
      • โคต๏ธInstallation
        • ๐Ÿ‘œAdd Item
      • ๐Ÿ“’Configuration
        • ๐Ÿ’ชCore
        • ๐Ÿ‘œInventory
        • ๐Ÿ‘€Target
        • ๐ŸŽฎMinigame
      • ๐Ÿ‘จโ€๐Ÿ’ปCustomization
        • ๐Ÿ”ฅExplosive Crate
        • ๐Ÿ“งMail
    • ๐ŸŽ๏ธDealership
      • โคต๏ธInstallation
        • ๐Ÿ‘œAdd Item
        • ๐Ÿ‘จโ€๐Ÿ’ปInitializing/Configuration
        • ๐Ÿ“ธGenerate Vehicle Images
      • ๐Ÿ“’Configuration
        • ๐Ÿ’ชCore
        • ๐Ÿ‘œInventory
        • ๐Ÿ‘€Target
        • ๐Ÿ““Miscellaneous
      • ๐ŸฌHow to Add Custom Shop
      • โš ๏ธImportant Notes
  • ๐ŸŽFREE RELEASE
    • ๐Ÿ“ปRadio
      • โคต๏ธInsallation
        • ๐ŸŒ‰Bridge Setup
        • ๐Ÿ‘œAdd Item
        • ๐Ÿ‘จโ€๐Ÿ’ปHow to build svelte ui file?
      • ๐Ÿ“’Configuration
        • ๐Ÿ—ผJammer System
        • ๐Ÿ”‹Battery
        • ๐Ÿ“ปChannel Name
        • ๐Ÿ“ปRestricted Radio Channel
      • ๐Ÿ‘จโ€๐Ÿ’ปExports
      • ๐Ÿ’ปBranch
    • ๐Ÿ”‘Car Keys
      • โคต๏ธInstallation
        • ๐Ÿ‘œAdd Item
      • ๐Ÿ“’Configuration
        • ๐Ÿ’ชCore
        • ๐Ÿ‘œInventory
        • ๐Ÿ‘œStack Key
      • ๐Ÿ‘จโ€๐Ÿ’ปUseful Exports
Powered by GitBook
On this page
  1. Paid Release
  2. Dealership

Important Notes

Upon performing all the steps mentioned before, you can witness a folder data with all the vehicles informations same like vehicles.lua for qb-core.

Here You can go both way on adding new vehicles:

  1. You can add new vehicles directly to data folder in the mm_dealership and vehicles.lua in QBCore

If you do it this, way you dont have to modify any vehicles.lua dependent scripts. Just update new vehicles to both Dealership Script and QBCore

  1. You can add new vehicles to mm_dealership only.

If you follow this Process, then you need to add these sets of line for all the script which requires QBCore.Shared.Vehicles data, to update the vehicle list

Client Side Event to Update QBCore.Shared.Vehicles

RegisterNetEvent('Dealership:Client:UpdateVeh', function(data)
    QBCore.Shared.Vehicles = data
end)

Server Side Event to Update QBCore.Shared.Vehicles

RegisterNetEvent('Dealership:Server:UpdateVeh', function(data)
    QBCore.Shared.Vehicles = data
end)

Events are used to update vehicles.lua for scripts which starts before mm_dealership

Export to Update QBCore.Shared.Vehicles

local vehicles = exports.mm_dealership.GetVehicles()
QBCore.Shared.Vehicles = vehicles

Exports are used to update vehicles.lua for scripts which starts after mm_dealership

Last updated 1 year ago

๐Ÿ’ฐ
๐ŸŽ๏ธ
โš ๏ธ