Installation
This guide will walk you through installing prp-drug-drops on your FiveM server.
Installation steps
prp-drug-drops from the CFX portal and place it in your resources folder.prp-drug-drops to your server.cfg after all dependencies. ensure oxmysql
ensure ox_lib
ensure prp-bridge
ensure prp-drug-dropsensure oxmysql
ensure ox_lib
ensure prp-bridge
ensure prp-drug-drops or use installation/sql/init.sql.config.lua: set Config.Debug to false, configure Mission group and policeRequired, StartingNpc locations, Config.Runs (routes, spawns, drop points, rewards), and Requirements.itemPoints.installation/inventory icons folder. Copy them to your inventory resource's image directory if you'd like to use them.CREATE TABLE IF NOT EXISTS `drug_drop_times` (
`id` INT AUTO_INCREMENT PRIMARY KEY,
`zone_id` VARCHAR(50) NOT NULL,
`route_index` INT NOT NULL,
`completion_time` INT NOT NULL,
`state_ids` TEXT NOT NULL,
`completed_at` TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
INDEX `idx_zone_route` (`zone_id`, `route_index`),
INDEX `idx_completion_time` (`completion_time`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;Items
Add the delivery box item to your inventory resource. The drug items used as input (pure_meth_brick_*, cocaine_brick, mdma_brick, etc.) come from other crime scripts and do not need to be added here.
Add the item below to your ox_inventory into data/items.lua. A ready-made entry is also included in installation/items/ox_inventory.lua.
["drug_drops_box"] = {
label = "Suspicious Package",
weight = 5000,
stack = false,
buttons = {
{
label = "Unbox",
action = function(slot)
TriggerServerEvent("prp-drug-drops:server:openDrugBox", slot)
end,
}
}
},TIP
The drug_drops_box item uses item metadata to store which drugs it contains. Make sure your inventory resource supports item metadata.
WARNING
The drug items required to start the run (pure_meth_brick_*, cocaine_brick, cocaine_mission_brick, mdma_brick, water) must already exist in your inventory. These are provided by other crime scripts. Make sure those resources are running before prp-drug-drops.