For all support questions, ask in our Discord support chat. Do not create issues if you need help. Issues are for bug reporting and new features only.
- QBCore | or | ESX 1.9.4+ & esx_license
- ps-dispatch
- oxmysql
- qb-apartments | Config available to enable or disable.
- Download ZIP
- Drag and drop resource into your server files, make sure to remove -main in the folder name
- Run the attached SQL script (mdt.sql)
- Start resource through server.cfg
- Restart your server.
Adds server export for inserting weaponinfo records, that can be used elsewhere in your server, such as weapon purchase, to add information to the mdt. Below is the syntax for this, all arguments are strings.
exports['ps-mdt']:CreateWeaponInfo(serial, imageurl, notes, owner, weapClass, weapModel)
- Your citizens can self-register weapons found on their inventory. Event to trigger is below if you're using qb-target.
ps-mdt:client:selfregister
9fda3730fdeb2c254d13696fb104131d.mp4
- Set Config.UseCQCMugshot to true, It is true by default. (Line 5 in Config.lua)
Config.UseCQCMugshot = true
- Choose what photos you want by changing this: (Line 8 in Config.lua)
-- Front, Back Side. Use 4 for both sides, we recommend leaving at 1 for default.
Config.MugPhotos = 1
- Create a Discord Webhook and paste it here: (Line 11 in Config.lua)
-- Images for mug shots will be uploaded here. Add a Discord webhook.
Config.Webhook = ''
- If you're getting kicked for attempted exploit abuse when jailing. Located the follow event below on qb-policejob > server > main.lua
police:server:JailPlayer
- Then comment out around line 779 as seen below
-- if #(playerCoords - targetCoords) > 2.5 then return DropPlayer(src, "Attempted exploit abuse") end
- lj-inventory will come already with the changes needed for this to work.
- qb-inventory follow instructions below.
- Edit the following event
RegisterNetEvent('inventory:server:SetInventoryData', function(fromInventory, toInventory, fromSlot, toSlot, fromAmount, toAmount)
elseif QBCore.Shared.SplitStr(shopType, "_")[1] == "Itemshop" then
if Player.Functions.RemoveMoney("cash", price, "itemshop-bought-item") then
if QBCore.Shared.SplitStr(itemData.name, "_")[1] == "weapon" then
itemData.info.serie = tostring(QBCore.Shared.RandomInt(2) .. QBCore.Shared.RandomStr(3) .. QBCore.Shared.RandomInt(1) .. QBCore.Shared.RandomStr(2) .. QBCore.Shared.RandomInt(3) .. QBCore.Shared.RandomStr(4))
itemData.info.quality = 100
end
local serial = itemData.info.serie
local imageurl = ("https://cfx-nui-qb-inventory/html/images/%s.png"):format(itemData.name)
local notes = "Purchased at Ammunation"
local owner = Player.PlayerData.charinfo.firstname .. " " .. Player.PlayerData.charinfo.lastname
local weapClass = 1
local weapModel = QBCore.Shared.Items[itemData.name].label
AddItem(src, itemData.name, fromAmount, toSlot, itemData.info)
TriggerClientEvent('qb-shops:client:UpdateShop', src, QBCore.Shared.SplitStr(shopType, "_")[2], itemData, fromAmount)
QBCore.Functions.Notify(src, itemInfo["label"] .. " bought!", "success")
exports['ps-mdt']:CreateWeaponInfo(serial, imageurl, notes, owner, weapClass, weapModel)
TriggerEvent("qb-log:server:CreateLog", "shops", "Shop item bought", "green", "**"..GetPlayerName(src) .. "** bought a " .. itemInfo["label"] .. " for $"..price)
elseif bankBalance >= price then
Player.Functions.RemoveMoney("bank", price, "itemshop-bought-item")
if QBCore.Shared.SplitStr(itemData.name, "_")[1] == "weapon" then
itemData.info.serie = tostring(QBCore.Shared.RandomInt(2) .. QBCore.Shared.RandomStr(3) .. QBCore.Shared.RandomInt(1) .. QBCore.Shared.RandomStr(2) .. QBCore.Shared.RandomInt(3) .. QBCore.Shared.RandomStr(4))
itemData.info.quality = 100
end
local serial = itemData.info.serie
local imageurl = ("https://cfx-nui-qb-inventory/html/images/%s.png"):format(itemData.name)
local notes = "Purchased at Ammunation"
local owner = Player.PlayerData.charinfo.firstname .. " " .. Player.PlayerData.charinfo.lastname
local weapClass = 1
local weapModel = QBCore.Shared.Items[itemData.name].label
AddItem(src, itemData.name, fromAmount, toSlot, itemData.info)
TriggerClientEvent('qb-shops:client:UpdateShop', src, QBCore.Shared.SplitStr(shopType, "_")[2], itemData, fromAmount)
QBCore.Functions.Notify(src, itemInfo["label"] .. " bought!", "success")
exports['ps-mdt']:CreateWeaponInfo(serial, imageurl, notes, owner, weapClass, weapModel)
TriggerEvent("qb-log:server:CreateLog", "shops", "Shop item bought", "green", "**"..GetPlayerName(src) .. "** bought a " .. itemInfo["label"] .. " for $"..price)
else
QBCore.Functions.Notify(src, "You don't have enough cash..", "error")
end
Support for Wolfknight Radar & Plate Reader https://github.com/WolfKnight98/wk_wars2x
Plate reader automatically locks and alerts Police if:
- Vehicle owner is Wanted
- Vehicle owner has no drivers licence
- Vehicle has a BOLO
IMPORTANT:
- Ensure you set "CONFIG.use_sonorancad = true" in wk_wars2x/config.lua
This reduces the plate reader events to player's vehicles and doesn't query the database for hundreds of NPC vehicles
- When initiating a traffic stop allows you to notify your fellow officers of your location and provide details about the current location and stopped vehicle through the radial menu.
- Add the following code right above
function READER:Main()
oncl_plate_reader.lua
local Vehicle = nil
local function GetFrontPlate()
local data = {
locked = READER.vars.cams["front"].locked,
plate = READER.vars.cams["front"].plate,
veh = Vehicle,
}
return data
end exports("GetFrontPlate", GetFrontPlate)
- Add the following into
cl_plate_reader.lua
afterlocal veh = UTIL:GetVehicleInDirection( PLY.veh, start, offset )
on the functionfunction READER:Main()
if i == 1 then
Vehicle = veh
end
- Add ps-mdt:client:trafficStop into the Radialmenu
- Preview.
- You need a Google Document / Sheet link that is viewable.
Paste the link you got in the config here:
-- Google Docs Link
Config.sopLink = {
['police'] = '',
['ambulance'] = '',
['bcso'] = '',
['doj'] = '',
['sast'] = '',
['sasp'] = '',
['doc'] = '',
['lssd'] = '',
['sapr'] = '',
}
-- Google Docs Link
Config.RosterLink = {
['police'] = '',
['ambulance'] = '',
['bcso'] = '',
['doj'] = '',
['sast'] = '',
['sasp'] = '',
['doc'] = '',
['lssd'] = '',
['sapr'] = '',
}
- How do I add charges to a criminal in an Incident? - After finding and adding the criminal citizen to the incident, right-click in the space under the criminal's name and select "Add Charge".
- My dispatch calls are not being populated? - You have not started the dispatch resource before the mdt or renamed the dispatch resource name and not made the necessary changes in mdt to reflect that.
The below repos are direct forks of ps-mdt and have been edited to fit certain countries/look.
- Originally Echo RP MDT released by Flawws#999
- CQC-Scripting for their cqc-mugshot
- JoeSzymkowicz
- MonkeyWhisper
- Snipe
- BackSH00TER
- nggcasey
- OK1ez
- Crayons0814
- LeSiiN
- ImXirvin
- lenzh
- Everyone else that we may have missed, thank you!