[RELEASE & FREE & QB] Metadata for vehiclekeys - MBL-Vehiclekeys

Previews:

Available Framework: QBCore
Credit: QBCore

Features:
You can’t lock your motorcycle, only engine start&stop.
Each vehicle has its own key.
You need to integration with your cardealer, I don’t support.
if your vehicle class is muscle, you need near your muscle vehicle it work with different animation.

REQ
  1. qb-core
  2. qb-inventory
  3. qb-taskbarskill (if you dont have GitHub - mb-later/qb-taskbarskill)

qb-inventory itemInfo:

Javascript
else if (itemData.name == "carkey") {

            $(".item-info-title").html('<p>'+itemData.info.model+' Keys</p>')

            $(".item-info-description").html('<p><strong>License Plate: </strong><span>' + itemData.info.plaka + '</span></p><p><strong></strong><span></span></p><p><strong>Model: </strong><span>' + itemData.info.model + '</span></p>');

        }

GiveItem example:

Example
local info = {
    model = veh,
    plaka = plate
}

--Client: TriggerServerEvent("QBCore:Server:AddItem","carkey",1,false,info)

--{{Server}}
-- local xplayer = QBCore.Functions.GetPlayer(source)
-- if xplayer then
--     xplayer.Functions.AddItem("carkey", 1, false, info)
-- end

Download

For the test, I printed the texts in the pictures, you will see the real values

6 Likes

tutorial? I try to do this and it doesn’t work for me …

2 Likes

yes tutorial

2 Likes

when i available i will

ESX version?

1 Like

Dalbys advise to add? Or help on how to add to the script to get the keys: P Thank you

please make an tutorial. and give advice for vehicleshop. thanks alot