Steal Systems

Welcome to Steal System

Quasar Inventory has an exclusive event for caching systems or searching other players inventories, therefore we must follow this modification to enable thefts in your factions.

The code that you see below must be executed:

TriggerServerEvent("inventory:server:OpenInventory", "otherplayer", GetPlayerServerId(closestPlayer))

I will leave you a small example of how this event will be executed, please read it patiently and execute it on the asset you want:

RegisterNetEvent('event:search')
AddEventHandler('event:search', function(closestPlayer)
    local closestPlayer, closestDistance = ESX.Game.GetClosestPlayer()
    if closestPlayer ~= -1 and closestDistance <= 3.0 then
        TriggerServerEvent("inventory:server:OpenInventory", "otherplayer", GetPlayerServerId(closestPlayer))
    end
end)

To facilitate your work, I will also attach here the esx_policejob in its latest version, with the added police search system and the blocking of inventory through exports when you are in handcuffs, remember that it will only work with the latest esx-legacy or its latest versions.

Last updated