🆘
Documentation
  • 👋Welcome to T3 Dev
  • Resources
    • 🪄t3_lib
      • Installation
    • 🎴t3_tradingcards
      • Installation
      • Snippets
      • Adding new packs
      • Common Issues
    • 💯t3_grading
      • Installation
      • Snippets
    • 💰t3_comicrobbery
      • Installation
      • Snippets
    • 🚴‍♂️t3_deliveroo
      • Installation
    • 🛤️t3_trainjob
      • Installation
  • External Links
    • Tebex
    • Discord
    • GitHub
Powered by GitBook
On this page
  1. Resources
  2. t3_lib

Installation

Last updated 1 year ago

  1. Download the latest version of t3_lib from

  2. Drag t3_lib to your server's resources folder and add ensure t3_lib to your server.cfg (make sure this is before any other t3 scripts)

  3. Config In the config.lua you will find some options you need to set up. The commented sections at the end of each line will tell you the currently supported options for each setting.

    Config.Framework = 'ESX'    --'ESX', 'QB'
    Config.Inventory = 'ox'     -- 'ox', 'esx', 'qb', 'qs', 'mf'
    Config.Target = 'ox_target' -- 'ox_target', 'qb-target'

  4. Notifications In the client/main.lua file you will find the notify function. This will need to be edited to use whatever notification script you have on your server. Some common examples have been provided.

    --Notify Event (You can add your own notification event here or use one of the provided examples)
    RegisterNetEvent("t3_lib:notify", function(data)
        local n = {
            msg = data.msg,
            title = data.title or "Notification",
            duration = data.duration or 5000,
            type = data.type or "info",
        }
        ESX.ShowNotification(n.msg, n.type, n.duration)
        --QBCore.Functions.Notify(n.msg, (n.type == "info" and "primary" or n.type), n.duration)
        --exports['okokNotify']:Alert(n.title, string.gsub(n.msg, '(~[rbgypcmuonshw]~)', ''), n.duration, n.type)
        --exports['mythic_notify']:DoCustomHudText(n.type, string.gsub(n.msg, '(~[rbgypcmuonshw]~)', ''), n.duration)
    end)

🪄
GitHub