[ESX] mdm_documents, id card and much more

The mdm_documents script is a script that adds documents. By default, it includes a gun license, ID card, and driver’s license, but it’s easy to add documents such as those for the police. The script fully saves in the database who the document belongs to, and even after transferring it to another player, it displays the owner’s data saved at the time of document issuance. Each document is assigned a unique ID, making it useful for various types of police tablets, etc. This script is written for the ESX framework and requires an inventory to function. It was initially developed for the ox_inventory, but since it’s open source, it can be easily modified. The only requirement is for the inventory to allow metadata assignment. Messages, menus, and targets are written for ox_lib and ox_target, but they can be easily adapted to your own. The options in the menu are available depending on the licenses you have, i.e. if you do not have a firearm license, you cannot obtain a document showing that you have a firearm license. To obtain each document, you must have a photo taken with you

Preview: YouTube
Buy: Tebex

This is how config looks like

Config = {}
Config.Distance = 3.0

Config.Notification = function(title, msg, type)
    if type == "success" then
        lib.notify({
            title = title,
            description = msg,
            position = 'top',
            type = 'success'
        })
    elseif type == "error" then
        lib.notify({
            title = title,
            description = msg,
            position = 'top',
            type = 'error'
        })
    end
end

Config.DisplayTexts = {
    ["drive_bike"] = {
        have = "A",
        notHave = ""
    },
    ["drive"] = {
        have = "B",
        notHave = "",
    },
    ["drive_truck"] = {
        have = "C",
        notHave = "",
    },
    ["weapon"] = {
        have = "Tak",
        notHave = "Nie",
    }
}

Config.PhotoPrice = 40
Config.IdCardPrice = 50
Config.DrivingCardPrice = 50
Config.WeaponCardPrice = 50

Config.Documents = {
    ["photo"] = {
        item = 'photo',
        animation = { "random@atmrobberygen", "a_atm_mugging" },
        animationTimeout = 2500,
        notifyText = "Pokazałeś zdjęcie",
        notifyYourSelfText = "Zobaczyłeś zdjęcie",
    },
    ["id_card"] = {
        item = 'idcard',
        color = "#333aa3",
        animation = { "random@atmrobberygen", "a_atm_mugging" },
        animationTimeout = 2500,
        background = "idcard",
        notifyText = "Pokazałeś dowód osobisty",
        notifyYourSelfText = "Zobaczyłeś dowód osobisty",
    },
    ["id_drive"] = {
        item = 'drivingcard',
        color = "#333aa3",
        animation = { "random@atmrobberygen", "a_atm_mugging" },
        animationTimeout = 2500,
        background = "drivingcard",
        notifyText = "Pokazałeś prawo jazdy",
        notifyYourSelfText = "Zobaczyłeś prawo jazdy",
    },
    ["id_weapon"] = {
        item = 'weaponcard',
        color = "#b0b0b0",
        animation = { "random@atmrobberygen", "a_atm_mugging" },
        animationTimeout = 2500,
        background = "weaponcard",
        notifyText = "Pokazałeś licencję na broń",
        notifyYourSelfText = "Zobaczyłeś licencję na broń",
    },
}

Config.Texts = {
    ["notify_title"] = "Dowód",
    ["notify_title_photo"] = "Urząd",
    ["no_have_photo"] = "Nie masz zrobionego zdjęcia do dokumentu, najpierw musisz je zrobić.",
    ["error_with_document"] = "Błąd uzyskania dokumentu.",
    ["you_paid_for_photo"] = "Zrobiłeś zdjęcie do dokumentu",
    ["you_do_photo"] = "Zrobiłeś zdjęcie do dokument",
    ["not_have_money"] = "Nie masz na tyle pieniędzy",
}

Code is accessible Yes
Subscription-based No
Lines (approximately) about 1000
Requirements ESX, INVENTORY with metadata support, MugShotBase64
Support Yes

My other resources:

2 Likes