[PAID][ESX] Original NPC Selling Drugs

Hello here is a drug sales script for npc with several possible options.

I tried to make a complete script that everyone would like.

This script is written to work with [OX] and [ESX Legacy]

Features :

  • Recruit players and set a percentage on their sale

  • Management of your sellers

  • Recruit NPCs for your protection

  • Sell drugs

  • Animations and dialogues

  • Mini game

  • forbidden Zones

Dependencies:

  • ESX
  • Ox_lib
  • Ox_inventory
  • Ox_target
  • Cd-dispatch or modify

Config

 
config.command = "recruitdrugs"
config.distanceTarget = 5
config.skillCheck = true -- minigame
config.difficulty = 'easy' -- easy/medium/hard (minigame)
config.keygame = 'e' -- key minigame ex: 'e', ​​'a' one/two or more put one key or more for difficulty (minigame)
config.failedSalePercentage = 30  -- You can adjust this percentage according to your needs police alert
config.recruitnpc = true -- recruit protection npc ()
config.recruitplayer = true -- recruit players who sell for you
config.NPCHostile = true -- hostile npc if the sale is lost
config.sellingNotInVehicle = true
 
config.jobblacklist = {
    'police',
    'sheriff',
}
 
config.itemsToSell = {
    { label = "Coke", name = "coke_pooch", desc = "", icon = "fa-capsules", distance = 5, price = 100, min = 1, max = 5 },
    { label = "Weed", name = "weed_pooch", desc = "", icon = "fa-leaf", distance = 5, price = 50, min = 1, max = 5 },
    { label = "Meth", name = "meth_pooch", desc = "", icon = "fa-flask", distance = 5, price = 150, min = 1, max = 5 }
    -- Add more items here as needed
}
 
config.forbiddenZones = {
    --{x = 30.97, y = -1876.95, z = 22.79, radius = 100},
    -- Add other areas here if necessary
}

config.maxNPCs = 5 -- max npc you can recruit
config.npcModels = {
    "g_f_importexport_01",  -- Replace these model names with the actual models you want to recruit
    "g_f_y_ballas_01",
    "g_f_y_families_01",
    "g_f_y_lost_01",
    "g_f_y_vagos_01",
    "g_m_importexport_01",
    "g_m_m_armboss_01",
    "g_m_m_armgoon_01",
    "g_m_m_armlieut_01",
    "g_m_m_chicold_01",
    "g_m_m_chigoon_01",
    "g_m_m_chigoon_02",
    "g_m_m_korboss_01",
    "g_m_m_mexboss_01",
    "g_m_m_mexboss_02",
    "g_m_y_armgoon_02",
    "g_m_y_azteca_01",
    "g_m_y_ballaeast_01",
    "g_m_y_ballaorig_01",
    "g_m_y_ballasout_01",
    "g_m_y_famca_01",
    "g_m_y_famdnf_01",
    "g_m_y_famfor_01",
    "g_m_y_korean_01",
    "g_m_y_korean_02",
    "g_m_y_korlieut_01",
    "g_m_y_lost_01",
    "g_m_y_lost_02",
    "g_m_y_lost_03",
    "g_m_y_mexgang_01",
    "g_m_y_mexgoon_01",
    "g_m_y_mexgoon_02",
    "g_m_y_mexgoon_03",
    "g_m_y_pologoon_01",
    "g_m_y_pologoon_02",
    "g_m_y_salvaboss_01",
    "g_m_y_salvagoon_02",
    "g_m_y_salvagoon_03",
    "g_m_y_strpunk_01",
    "g_m_y_strpunk_02",
    "g_m_m_casrn_01",
}
 
config.BlacklistModels = {
    'a_c_chickenhawk',  -- Faucon
    'a_c_chimp',        -- Chimpanzé
    'a_c_chop',         -- Chop (Chien)
    'a_c_cormorant',    -- Cormoran
    'a_c_cow',          -- Vache
    'a_c_coyote',       -- Coyote
    'a_c_deer',         -- Cerf
    'a_c_fish',         -- Poisson
    'a_c_hen',          -- Poule
    'a_c_cat_01',       -- Chat
    'a_c_humpback',     -- Baleine à bosse
    'a_c_husky',        -- Husky
    'a_c_killerwhale',  -- Orque
    'a_c_mtlion',       -- Puma
    'a_c_pig',          -- Cochon
    'a_c_pigeon',       -- Pigeon
    'a_c_poodle',       -- Caniche
    'a_c_pug',          -- Carlin
    'a_c_rabbit_01',    -- Lapin
    'a_c_rat',          -- Rat
    'a_c_retriever',    -- Retriever
    'a_c_rhesus',       -- Macaque rhésus
    'a_c_rottweiler',   -- Rottweiler
    'a_c_seagull',      -- Mouette
    'a_c_sharktiger',   -- Requin-tigre
    'a_c_shepherd',     -- Berger Allemand
    'a_c_westy'         -- Westie
    -- Add other animal models if necessary
}
 
config.language = {
    drugselling = "Drug Selling",
    errorselling = "Selling Error",
    errorvehicle = "Selling in a vehicle is prohibited.",
    errorsellingdesc = "You cannot sell while in a vehicle.",
    errorsellingdesc2 = "You have already sold to this NPC.",
    errorsellingdesc3 = "You have nothing to sell",
    errorsellingdesc4 = "You do not have the minimum required quantity %s",
    menutitle = "Product Sales",
    commissionvalid = "Commission Received",
    percentcommi = "You have received a commission of %s$.",  
    salecompleted = "Sale Completed",
    salecompleteddesc = "You sold for %s$ and for %s bags.", 
    recruitplayer = "Recruit a Player",
    recruitmentheader = "Player Recruitment",
    recruitmentcontent = "Enter the commission rate (as a percentage): ",
    commissionpercentage = "Commission Rate",
    recruit = "Recruit",
    cancel = "Cancel",
    playerrecruited = "Player Recruited",
    recruitmentplayererror = "This player is already recruited.",
    playerrecruiteddesc = "You have recruited a player for drug sales with a commission",
    recruitmenterror = "Recruitment Error",
    recruitmenterrordesc1 = "This NPC has already been recruited.",
    recruitmenterrordesc2 = "You cannot recruit this type of NPC.",
    recruitmentsuccess = "Recruitment Successful",
    recruitmentsuccessdesc = "You have recruited an NPC for your protection.",
    recruitnpc = "Recruit an NPC",
    errorsellingdesc3 = "You must have at least %d of this item to sell it.",
    menuplayercommi = "Modify Commission Rate",
    deleteplayer = "Delete Seller",
    descdeleteplayer = "The recruited player has been successfully deleted.",
    echecdeleteplayer = "Failed to remove recruited player.",
    error = "Error",
    returnmenu = "Return",
    close = "Close",
    playerrecruit = "Recruited Players",
    sellingcount = "Number of Sales",
    descmenu = "Commission Rate: ",
    playerid = "Player ID: ",
    errorcommi = "Failed to update commission rate.",
    goodcommi = "Commission rate successfully updated.",
    errortaux = "Invalid entry. The commission rate has not been modified.",
    errorplayer = "Recruited player not found.",
    totcommi = "New commission rate (as a percentage):",
    deadnpc = "You cannot sell to a dead NPC.",
    jobblacklist = "Sales to certain jobs are prohibited.",
    recruitnotfound = "Recruit Not Found",
    playeridNot = "Not ID",
    notzoneselling = "Sales are prohibited in this area.",
    textyou = "~g~[You]~s~ Yo Man, don't you want a little thing?",
    textclient = "~b~[Citizen]~s~ Go ahead man, send it.",
}

Preview

Purchase Link [ESCROW] [OPEN SOURCE]

The Escrow version allows access to modification of dispatch and notification

No support other than dependencies. The Open Source version will allow you to adapt it to your convenience.

If you have any suggestions for improvement, please do not hesitate.

This resource uses FiveM’s Asset Escrow System

Code is accessible Yes/No
Subscription-based No
Requirements esx, ox_lib, ox_inventory, ox_target
Support Yes

Price 12,99€