LogoLogo
TebexDiscord
  • Information
    • 👋Welcome
    • 📄Before installation
  • QBCore
    • 👮Police Hub
      • Installation
      • Configuration
    • 🏨Hotel
      • Installation
      • Configuration
      • Common problems
    • 🔫Paint Ball
      • Installation
      • Configuration
    • 🛠️Crafting
      • Installation
      • Configuration
    • 🗺️Spying
      • Installation
      • Configuration
    • 💠HUD
      • Installation
      • Configuration
    • 🖼️Gangs Turf
      • Installation
      • Configuration
Powered by GitBook

2023 - 2024 All rights reserved

On this page
  • Dependencies
  • Asset download
  • Items installation
  • Metadata installation
  • Dependencies for inventory
  • Finally Customize Your setting in Config.lua
  1. QBCore
  2. Police Hub

Installation

Dependencies

Resource

Install

Required

Required

Asset download

  1. Download your resource from FiveM's Keymaster.

  2. Unzip zip folder and place it into your resource folder.

  3. Add ensure l2s-policehub to your server start config. Make sure to place anywhere below the framework and dependencies resources.

Items installation

["bodycam"] 			   = {["name"] = "bodycam", 			 	["label"] = "Bodycam", 				["weight"] = 500, 		["type"] = "item", 		["image"] = "bodycam.png", 				["unique"] = true, 		["useable"] = false, 	["shouldClose"] = true,	   ["combinable"] = nil,   ["description"] = "Body Camera for police"},

Metadata installation

PlayerData.metadata['policehub'] = PlayerData.metadata['policehub'] or {
        ['alerts'] = {
            ['enablealerts'] = true,
            ['autoclear'] = false,
            ['mute'] = false,
        },
        ['wings'] = {
            [1] = false,
            [2] = false,
            [3] = false,
            [4] = false,
            [5] = false,
            [6] = false,
            [7] = false,
            [8] = false,
            [9] = false,
        },
        ['direction'] = nil,
        ['Assignment'] = nil,
        ['OfficerPlayTime'] = 0,
    }
    PlayerData.metadata["dutybusy"] = PlayerData.metadata["dutybusy"] ~= nil and PlayerData.metadata["dutybusy"] or false
    PlayerData.metadata["dutybreak"] = PlayerData.metadata["dutybreak"] ~= nil and PlayerData.metadata["dutybreak"] or false

Dependencies for inventory

Add Item: Add This In AddItem Function : in qb-inventory or qb-core like

if item == 'bodycam' then
	TriggerClientEvent('l2s-policehub:client:togglebody', source)
end

Remove Item: Add This In RemoveItem Function : in qb-inventory or qb-core like

if item == 'bodycam' then
	TriggerClientEvent('l2s-policeuhub:client:cancelbody', -1, Player.PlayerData.source)
end

Finally Customize Your setting in Config.lua

And don't forget setup webhocks in config

Last updated 1 year ago

👮
oxmysql
screenshot-basic