Wert Merryweather Job
You can access the setup information you need about this product
INSTALLATION
1 - Upload the script folder to the location of your resources
2 - Don't forget to check that your target system and polyzone script are working (If you use target but polyzone requid everytime)
3 - Do not forget to add all the sql file contained in the folder to your database
4 - You can check the config file and customize it according to yourself
5 - Don't forget to add the job data below to your own job list
6 - Please add the items to your list in the items section below
7 - Installation successful, have a good funs
JOB LIST
The grade and its descriptions are as follows
-- Merryweather
['merryweather'] = {
label = 'Merryweather',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {
name = 'Recruit',
payment = 50
},
['1'] = {
name = 'Officer',
payment = 100
},
['2'] = {
name = 'Sergeant',
payment = 150
},
['3'] = {
name = 'Lieutenant',
payment = 200
},
['4'] = {
name = 'General',
isboss = true,
payment = 250
},
},
},
ITEMS
These are the default items and their codes, you can change them later if you want
Note : Item images in script folder
-- ITEMS
```lua
["merryweather_coffe_material"] = {
["name"] = "merryweather_coffe_material",
["label"] = "Granular Coffee",
["weight"] = 0,
["type"] = "item",
["image"] = "merryweather_coffe_material.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = true,
["combinable"] = nil,
["description"] = "Coffe Material"
},
["merryweather_coffe"] = {
["name"] = "merryweather_coffe",
["label"] = "Coffee",
["weight"] = 0,
["type"] = "item",
["image"] = "merryweather_coffe.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = true,
["combinable"] = nil,
["description"] = "Coffe"
},
["merryweather_documention"] = {
["name"] = "merryweather_documention",
["label"] = "Documention",
["weight"] = 0,
["type"] = "item",
["image"] = "merryweather_documention.png",
["unique"] = true,
["useable"] = true,
["shouldClose"] = true,
["combinable"] = nil,
["description"] = "Coffe Material"
},
["merryweather_idcard"] = {
["name"] = "merryweather_idcard",
["label"] = "Merryweather Security Card",
["weight"] = 0,
["type"] = "item",
["image"] = "merryweather_idcard.png",
["unique"] = true,
["useable"] = true,
["shouldClose"] = true,
["combinable"] = nil,
["description"] = "Coffe Material"
},
["merryweather_hackdevice"] = {
["name"] = "merryweather_hackdevice",
["label"] = "Merryweather Hack Device",
["weight"] = 0,
["type"] = "item",
["image"] = "merryweather_hackdevice.png",
["unique"] = true,
["useable"] = true,
["shouldClose"] = true,
["combinable"] = nil,
["description"] = "Hack Device For Merryweather Trucks"
},
```
OX LIB OPTION
There are many ox settings available in the files, if you want, you can configure them.
If you want to use ox_lib, please check if this link is enabled on fxmanifest.check it out from inside lua. this must be turned on before you can use ox_lib. After opening it, it will be enough to use the refresh and ensure commands.
OX INVENTORY IMPORTANT STEP
If you have turned on the ox inventory feature via config and you are an ox inventory user, please perform this step
1 - Go ox_inventory/modules/items/client.lua
2 - Place the Decodes below between the other item usage codes that are in the file.
```lua
Item('merryweather_documention', function(data, slot)
local metadata = slot.metadata
if not metadata or not metadata.photourl then return end
TriggerEvent("wert-merryweather:client:use-printer-docs", metadata.photourl)
end)
Item('merryweather_idcard', function(data, slot)
local metadata = slot.metadata
if not metadata or not metadata.cardno then return end
TriggerServerEvent("wert-merryweather:server:use-idcard-item-oxinv", metadata)
end)
```
OPEN FILES
Config File
```lua
Config = {}
Config.UseTarget = true
Config.JobName = 'merryweather'
Config.NoTargetActionKey = 38 -- [E] https://docs.fivem.net/docs/game-references/controls/
Config.DebugPoly = false
Config.OxLib = true
Config.OxInventory = false
Config.OxLibProgressbar = false
Config.DiscordLog = true
Config.SocietyName = 'merryweather'
Config.ActiveBlips = true
Config.Blips = {
{
coord = vector3(569.93, -3124.12, 18.77),
sprite = 124,
color = 49,
scale = 1.0,
title = "Merryweather"
}
}
Config.Zones = {
{
action = "duty",
coord = vector3(576.38, -3126.41, 18.77),
width = 3.0,
length = 0.2,
heading = 0,
minZ = 15.77,
maxZ = 19.77,
job = Config.JobName,
label = "On / Off Duty",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-briefcase",
},
{
action = "bossmenu",
coord = vector3(573.14, -3124.17, 18.77),
width = 0.8,
length = 1.0,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Boss Menu",
icon = "fa-solid fa-clipboard"
},
{
action = "coffemachine",
coord = vector3(573.01, -3120.29, 18.77),
width = 0.6,
length = 0.4,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Coffe Machine",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-mug-hot",
},
{
action = "watermachine",
coord = vector3(576.07, -3122.96, 18.77),
width = 0.6,
length = 0.6,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Dispenser",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-droplet",
},
{
action = "vehicleshop",
coord = vector3(565.25, -3124.78, 18.77),
width = 0.8,
length = 1.0,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Vehicleshop",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-car-side",
},
{
action = "printer",
coord = vector3(563.8, -3120.53, 18.77),
width = 1.0,
length = 1.0,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Printer",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-file",
},
{
action = "stash",
coord = vector3(562.55, -3126.92, 18.77),
width = 2.2,
length = 1.4,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Stash",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-box",
},
{
action = "firstaidbox",
coord = vector3(562.05, -3123.04, 18.77),
width = 0.6,
length = 0.4,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Medical Storage",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-kit-medical",
},
{
action = "weaponshop",
coord = vector3(567.04, -3116.7, 18.77),
width = 1.2,
length = 2.2,
heading = 356,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "Weapon Storage",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-box-open",
},
{
action = "repair",
coord = vector3(581.53, -3113.11, 6.07),
width = 2.2,
length = 1.2,
heading = 0,
minZ = 5.07,
maxZ = 7.47,
job = Config.JobName,
label = "Repair Table",
icon = "fa-solid fa-toolbox",
targeticon = "fa-solid fa-wrench",
},
{
action = "idcard",
coord = vector3(571.61, -3123.73, 18.77),
width = 1.6,
length = 0.8,
heading = 0,
minZ = 15.77,
maxZ = 19.77,
job = Config.JobName,
label = "Create Security Card",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-id-card-clip",
},
{
action = "order",
coord = vector3(563.79, -3124.31, 18.77),
width = 2.0,
length = 0.8,
heading = 0,
minZ = 15.77,
maxZ = 19.77,
job = Config.JobName,
label = "Shipments",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-ship",
},
{
action = "jobs",
coord = vector3(569.67, -3127.22, 18.77),
width = 1.0,
length = 1.8,
heading = 0,
minZ = 15.77,
maxZ = 19.77,
job = Config.JobName,
label = "Jobs",
icon = "fa-solid fa-caret-right",
targeticon = "fa-regular fa-clipboard",
},
}
-- # Garages
Config.GarageActionKey = 38 -- https://docs.fivem.net/docs/game-references/controls/
Config.Garages = {
{label = "Garage A (Car)", coord = vector3(468.09, -3190.92, 6.07), size = 8.3, useZ = true, car_type = "car", spawncoord = vector4(467.87, -3179.74, 6.07, 0.45)},
{label = "Garage B (Helicopter)", coord = vector3(478.48, -3369.81, 6.07), size = 7.0, useZ = true, car_type = "helicopter", spawncoord = vector4(478.31, -3368.93, 6.07, 182.36)},
{label = "Garage C (Boat)", coord = vector3(510.1, -3301.19, 6.07), size = 10.0, useZ = true, car_type = "boat", spawncoord = vector4(521.42, -3293.73, 0.1, 184.96)},
}
Config.ImpoundGarageKey = 38 -- https://docs.fivem.net/docs/game-references/controls/
Config.ImpoundedGarages = {
{
coord = vector4(503.75, -3122.03, 6.07, 181.05),
ped_model = `s_m_m_fiboffice_01`,
size = 2.5,
useZ = true,
},
}
-- # Vehicleshop
Config.MoneyFormat = 'en-US'
Config.TestDriveTime = 60 -- Second
Config.TestDriveCoord = vector4(-1725.32, -2919.72, 13.94, 239.07)
Config.UseSocietyMoneyWhenTryBuyVehicle = true -- | if you set false it use player own money
Config.NoSocietyMoneyType = 'bank' -- | "cash"
Config.VehicleshopVehicles = {
{model = "baller5", label = "Baller Le (Armored)", price = 10000, image = "https://static.wikia.nocookie.net/gtawiki/images/6/6c/BallerLEArmored-GTAO-front.png", car_type = "car", description = "A high-end armored vehicle specially designed for Merryweather. It is a sign that being an SUV is suitable for off-road driving. It can be strengthened by customizations. It is a baller brand for 4 People."},
{model = "xls2", label = "XLS (Armored)", price = 9000, image = "https://static.wikia.nocookie.net/gtawiki/images/e/e3/XLSArmored-GTAO-front.png/revision/latest/scale-to-width-down/1000?cb=20160609145239", car_type = "car", description = "Poised delicately between BAWSAQ chic and bone-crunching utility, the Benefactor XLS is every car to everyone. Whether you're attending a board meeting halfway up a rugged cliff face or ferrying humane remains out of your place of work, it's reassuring to know the Germans have got your back. Armored version available, obviously."},
{model = "cog552", label = "Cognoscenti 55 (Armored)", price = 8500, image = "https://static.wikia.nocookie.net/gtawiki/images/b/b0/Cognoscenti55Armored-GTAO-front.png/revision/latest/scale-to-width-down/1000?cb=20160117195143", car_type = "car", description = "The original Cog Cabrio was a landmark in bringing luxury grand tourers to a wider market, which explains why every five-figure broker with a pinstripe suit and a history of sexual assault has one. Invest in this new four-door model, with more headroom and a plush interior, and you should stand out of the crowd for at least another couple of months. Armored edition available."},
{model = "cognoscenti2", label = "Cognoscenti (Armored)", price = 8000, image = "https://static.wikia.nocookie.net/gtawiki/images/3/30/CognoscentiArmored-GTAO-front.png/revision/latest/scale-to-width-down/1000?cb=20160117195043", car_type = "car", description = "The original Cog Cabrio was a landmark in bringing luxury grand tourers to a wider market, which explains why every five-figure broker with a pinstripe suit and a history of sexual assault has one. Invest in this new four-door model, with more headroom and a plush interior, and you should stand out of the crowd for at least another couple of months. This model has an extended wheelbase. Armored edition available."},
{model = "schafter5", label = "Schafter V12 (Armored)", price = 8000, image = "https://static.wikia.nocookie.net/gtawiki/images/7/7c/SchafterV12Armored-GTAO-front.png/revision/latest/scale-to-width-down/1000?cb=20151216172126", car_type = "car", description = "Powerful, understated, reliable. You have absolutely none of these qualities, so it's important to you that your car does. The new Benefactor Schafter screams corporate anonymity just as much as its predecessor, so to justify the massive price hike we've thrown in a few flourishes and a plush interior where you can screw your secretary's secretary in comfort. Armored edition available."},
{model = "mesa3", label = "Mesa 3", price = 5500, image = "https://static.wikia.nocookie.net/gtawiki/images/6/6e/Mesa3-GTAO-RGSC-Action.jpg/revision/latest?cb=20200402190614", car_type = "car", description = "Is there a more iconic and uncomfortable 4WD on the market? Every 17-years-old girl wants to lease a Canis on spring break, which is why the Mesa comes with roll cage as standard."},
{model = "dinghy", label = "Dinghy", price = 3500, image = "https://static.wikia.nocookie.net/gtawiki/images/b/b6/Dinghy-GTAV-front.png/revision/latest/scale-to-width-down/1000?cb=20170723192359", car_type = "boat", description = "If you like your dinghies like you like your prophylactics then this is the one for you. A lightweight, high capacity rigid-hulled inflatable boat that's good enough for a team of sailors on shore leave."},
{model = "maverick", label = "Maverick", price = 150000, image = "https://static.wikia.nocookie.net/gtawiki/images/2/2b/Maverick-GTAV-front.png/revision/latest/scale-to-width-down/1000?cb=20160411164524", car_type = "helicopter", description = "A two-bladed, twin-engine helicopter, the Maverick was manufactured in Canada, but you shouldn't let that put you off. Originally designed for military use, when the army rejected them for looking too 'French', they became hugely popular with rich social climbers for exactly the same reason. Used by law enforcement for surveillance operations, you'll often see them hovering above inner city African American neighborhoods. Billion candlepower spotlight and loudspeaker optional, but trust us, it's fun to play with over poor neighborhoods at night."},
}
Config.Colors = {
{gameid = 111, csscolor = "white"},
{gameid = 28, csscolor = "rgb(230, 79, 79)"},
{gameid = 91, csscolor = "rgb(216, 214, 105)"},
{gameid = 92, csscolor = "rgb(137, 224, 119)"},
{gameid = 74, csscolor = "rgb(100, 173, 207)"},
{gameid = 145, csscolor = "rgb(155, 80, 204)"},
{gameid = 3, csscolor = "gray"},
{gameid = 27, csscolor = "rgb(223, 35, 35)"},
{gameid = 38, csscolor = "rgb(204, 155, 50)"},
{gameid = 53, csscolor = "rgb(50, 192, 137)"},
{gameid = 70, csscolor = "rgb(48, 109, 179)"},
{gameid = 72, csscolor = "rgb(128, 49, 180)"},
{gameid = 0, csscolor = "black"},
{gameid = 32, csscolor = "rgb(134, 6, 6)"},
{gameid = 36, csscolor = "rgb(204, 111, 5)"},
{gameid = 50, csscolor = "rgb(4, 90, 26)"},
{gameid = 73, csscolor = "rgb(5, 55, 190)"},
{gameid = 71, csscolor = "rgb(100, 0, 167)"},
}
-- # Doors
Config.UseAddonLockScript = false
-- If you Config.UseAddonLockScript = false Config.Doors work (Script use own door lock)
Config.Doors = {
["office_door_1"] = {
hash = 100,
coord = vector3(552.247437, -3117.247803, 18.918688),
lock = true,
model = 1388116908,
},
["office_door_2"] = {
hash = 101,
coord = vector3(585.969421, -3117.247803, 18.918688),
lock = true,
model = 1388116908,
},
}
Config.AutoCloseDefaultDoors = true
Config.DoorTargets = {
{
coord = vector3(552.44, -3118.89, 18.77),
width = 0.4,
length = 1.2,
heading = 4,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "1. Door",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-door-open",
door_id = "office_door_1"
},
{
coord = vector3(585.77, -3118.89, 18.71),
width = 0.4,
length = 1.2,
heading = 0,
minZ = 17.77,
maxZ = 19.77,
job = Config.JobName,
label = "2. Door",
icon = "fa-solid fa-caret-right",
targeticon = "fa-solid fa-door-open",
door_id = "office_door_2"
},
}
-- # Disable Peds A Area
Config.DisablePedsArea = true
Config.DisablePedsAreaCoord = vector3(525.71, -3189.07, 8.68)
Config.DisablePedsAreaSize = 1000
Config.DisablePedModels = {
[`s_m_y_blackops_01`] = true,
}
Config.FriendlyRelationGroup = true
-- # Water Machine
Config.WaterMachineGiveAmount = 25 -- Thirst
Config.WaterMachineSettings = {
fill_anim = {
dict = "anim@amb@clubhouse@tutorial@bkr_tut_ig3@",
anim = "machinic_loop_mechandplayer",
flag = 16
},
water_anim = {
dict = "mp_player_intdrink",
anim = "loop_bottle",
flag = 51,
prop = "prop_mug_06",
prop_bone = 18905,
prop_coord = {x = 0.12, y = 0.008, z = 0.03},
prop_rot = {x = 240.0, y = -60.0, z = 0.0},
}
}
-- # Printer
Config.PrinterItemName = "merryweather_documention"
Config.PrinterSettings = {
print_anim = {
dict = "anim@amb@clubhouse@tutorial@bkr_tut_ig3@",
anim = "machinic_loop_mechandplayer",
flag = 16
},
}
-- # Repair
Config.RepairItemImage = "qb-inventory/html/images"
Config.MinimumQualityValueForRepair = 90
Config.RepairItems = {
["weapon_assaultrifle"] = {
image = "./images/weapon_assaultrifle.png",
item_image = "qb-inventory/html/images/weapon_assaultrifle.png",
items = {
{name = "iron", label = "IRON", amount = 13, image = "nui://qb-inventory/html/images/iron.png"},
{name = "plastic", label = "PLASTIC", amount = 4, image = "nui://qb-inventory/html/images/plastic.png"},
{name = "rubber", label = "RUBBER", amount = 8, image = "nui://qb-inventory/html/images/rubber.png"},
},
objectsettings = {
model = `w_ar_assaultrifle`,
attach_settings = {bone = 28422, posX = 0.1, posY = 0.01, posZ = 0.0, rotX = 0.0, rotY = 0.0, rotZ = 0.0}
},
animationsettings = {dict = "anim@gangops@facility@servers@", name = "hotwire", flag = 1},
},
["weapon_carbinerifle"] = {
image = "./images/weapon_carbinerifle.png",
item_image = "qb-inventory/html/images/weapon_carbinerifle.png",
items = {
{name = "iron", label = "IRON", amount = 10, image = "nui://qb-inventory/html/images/iron.png"},
{name = "plastic", label = "PLASTIC", amount = 5, image = "nui://qb-inventory/html/images/plastic.png"},
{name = "rubber", label = "RUBBER", amount = 5, image = "nui://qb-inventory/html/images/rubber.png"},
},
objectsettings = {
model = `w_ar_carbinerifle`,
attach_settings = {bone = 28422, posX = 0.1, posY = 0.01, posZ = 0.0, rotX = 0.0, rotY = 0.0, rotZ = 0.0}
},
animationsettings = {dict = "anim@gangops@facility@servers@", name = "hotwire", flag = 1},
},
["weapon_pistol"] = {
image = "./images/weapon_pistol.png",
item_image = "qb-inventory/html/images/weapon_pistol.png",
items = {
{name = "iron", label = "IRON", amount = 5, image = "nui://qb-inventory/html/images/iron.png"},
{name = "plastic", label = "PLASTIC", amount = 1, image = "nui://qb-inventory/html/images/plastic.png"},
{name = "rubber", label = "RUBBER", amount = 3, image = "nui://qb-inventory/html/images/rubber.png"},
},
objectsettings = {
model = `w_pi_pistol`,
attach_settings = {bone = 28422, posX = 0.1, posY = 0.01, posZ = 0.0, rotX = 0.0, rotY = 0.0, rotZ = 0.0}
},
animationsettings = {dict = "anim@gangops@facility@servers@", name = "hotwire", flag = 1},
},
}
-- # Coffe
Config.CoffePrepareTime = 30 -- Second
Config.CoffeGiveAmount = 25 -- Thirst
Config.CoffeItems = {
{name = "water_bottle", amount = 1},
{name = "merryweather_coffe_material", amount = 1}
}
Config.CoffeItem = "merryweather_coffe"
Config.CoffeSettings = {
drink_anim = {
dict = "mp_player_intdrink",
anim = "loop_bottle",
flag = 51,
prop = "prop_mug_06",
prop_bone = 18905,
prop_coord = {x = 0.12, y = 0.008, z = 0.03},
prop_rot = {x = 240.0, y = -60.0, z = 0.0},
}
}
-- # Image
Config.ImagePropModel = "prop_tourist_map_01"
Config.ImagePropBone = 28422
Config.ImageAnimation = {
dict = "amb@world_human_tourist_map@male@base",
anim = "base",
flag = 1,
}
-- # ID Card
Config.IdCardItemName = "merryweather_idcard"
Config.DefaultIdCardPhoto = "" -- URL
Config.CloseIDCardKey = 194
Config.IdCardPropModel = "prop_franklin_dl"
-- # Order
Config.OrderPrepareTime = 60 -- Second 10 Minute now | 600
Config.OrderOnTheWayTime = 120 -- Second 30 Minute Now | 1800
Config.OrderWaitInHarbourTime = 30 -- Second 5 Minute now | 300
Config.OrderDeliveryTime = 120 -- Second 2 minute now | 120
Config.OrderItems = {
-- Weapons
{
name = "weapon_specialcarbine",
label = "Special Carbine Rifle",
price = 1000,
image = "nui://qb-inventory/html/images/weapon_specialcarbine.png",
storage_type = "weapon"
},
{
name = "weapon_combatpdw",
label = "Combat PDW",
price = 800,
image = "nui://qb-inventory/html/images/weapon_combatpdw.png",
storage_type = "weapon"
},
{
name = "weapon_assaultshotgun",
label = "Assault Shotgun",
price = 700,
image = "nui://qb-inventory/html/images/weapon_assaultshotgun.png",
storage_type = "weapon"
},
{
name = "weapon_heavypistol", -- Item Name
label = "Heavy Pistol", -- Item Label
price = 500, -- 1 Amount Price
image = "nui://qb-inventory/html/images/weapon_heavypistol.png", -- Image URL
storage_type = "weapon" -- "weapon" | "medical"
},
{
name = "weapon_knuckle", -- Item Name
label = "Knuckle", -- Item Label
price = 300, -- 1 Amount Price
image = "nui://qb-inventory/html/images/weapon_knuckle.png", -- Image URL
storage_type = "weapon" -- "weapon" | "medical"
},
-- Ammos
{
name = "pistol_ammo",
label = "Pistol Ammo",
price = 10,
image = "nui://qb-inventory/html/images/pistol_ammo.png",
storage_type = "weapon"
},
{
name = "smg_ammo",
label = "SMG Ammo",
price = 15,
image = "nui://qb-inventory/html/images/smg_ammo.png",
storage_type = "weapon"
},
{
name = "rifle_ammo",
label = "Rifle Ammo",
price = 20,
image = "nui://qb-inventory/html/images/rifle_ammo.png",
storage_type = "weapon"
},
-- Armor
{
name = "heavyarmor",
label = "Heavy Armor",
price = 50,
image = "nui://qb-inventory/html/images/armor.png",
storage_type = "weapon"
},
-- Medical
{
name = "firstaid",
label = "First Aid",
price = 15,
image = "nui://qb-inventory/html/images/firstaid.png",
storage_type = "medical"
},
{
name = "painkillers",
label = "Painkillers",
price = 15,
image = "nui://qb-inventory/html/images/painkillers.png",
storage_type = "medical"
},
{
name = "bandage",
label = "Bandage",
price = 10,
image = "nui://qb-inventory/html/images/bandage.png",
storage_type = "medical"
},
}
-- # Progressbar Times
Config.ProgressbarTimes = {
water_fill = 5000,
water_drink = 5000,
printer = 5000,
coffe_drink = 5000,
repair_weapon = 10000,
money_transfer_take_bag = 3500,
money_transfer_deliver_bag = 2500,
}
```
Config_jobs File
```lua
Config.Jobs = {
["moneytransport"] = {
car_model = "stockade",
car_spawn_coord = vector4(490.67, -3155.07, 6.07, 1.28),
needed_go_bank_amount = 3,
bank_transport_bag_amount = 3,
reward_for_merryweather = {r1 = 5000, r2 = 10000}, -- When job succesfull finish merryweather case earn Money math.random(r1, r2)
random_active_times = { -- A random clock is selected and activated between this selected hour
{min = 17, max = 23},
},
menu_label = "Money Transport Mission",
menu_icon = "landmark",
car_store_coord = vector4(-46.3, -762.13, 32.82, 161.1),
car_store_checkpoint_sprite = 47,
banks = {
-- Coords
{bank_coord = vector4(148.51, -1040.22, 29.38, 176.32), delivery_bag = vector4(147.1, -1045.04, 29.37, 252.58)},
{bank_coord = vector4(313.65, -278.88, 54.17, 235.02), delivery_bag = vector4(311.63, -283.38, 54.17, 252.68)},
{bank_coord = vector4(-352.63, -49.31, 49.05, 229.99), delivery_bag = vector4(-353.5, -54.46, 49.04, 250.65)},
{bank_coord = vector4(-1213.81, -331.3, 37.79, 292.75), delivery_bag = vector4(-1211.23, -335.52, 37.78, 299.02)}
}
},
["guard"] = {
car_model = "xls2",
car_spawn_coord = vector4(490.67, -3155.07, 6.07, 1.28),
npc_spawn_coord = vector4(492.86, -3156.68, 6.07, 4.74),
reward_for_merryweather = {r1 = 5000, r2 = 10000}, -- When job succesfull finish merryweather case earn Money math.random(r1, r2)
random_active_times = { -- A random clock is selected and activated between this selected hour
{min = 17, max = 23},
},
checkpoint_sprite = 47,
menu_label = "Guard Mission",
menu_icon = "shield",
car_store_coord = vector4(-46.3, -762.13, 32.82, 161.1),
car_store_checkpoint_sprite = 47,
delivery_locations = {
{coord = vector4(917.73, 50.11, 80.9, 325.4), walk_coord = vector4(934.81, 45.23, 81.1, 326.54), information = LANG.guard_casino_mid, ped_models = "casinomodels"},
{coord = vector4(228.21, 213.51, 105.52, 21.56), walk_coord = vector4(241.77, 223.44, 106.29, 263.55), information = LANG.guard_pacificbank_mid, ped_models = "pacificbank"},
{coord = vector4(245.05, -379.88, 44.5, 252.16), walk_coord = vector4(238.91, -409.86, 47.92, 161.91), information = LANG.guard_judge_mid, ped_models = "judge"},
{coord = vector4(-512.36, -262.08, 35.43, 114.18), walk_coord = vector4(-542.82, -208.01, 37.65, 27.78), information = LANG.guard_governor_mid, ped_models = "governor"},
{coord = vector4(-1036.91, -2728.22, 20.08, 248.0), walk_coord = vector4(-1042.54, -2745.6, 21.36, 153.41), information = LANG.guard_businessman_mid, ped_models = "businessman"},
}
}
}
Config.MoneyTransferBankBlip = {
sprite = 106,
color = 2,
scale = 1.0,
label = "Target Bank"
}
Config.MoneyBagSettings = {
bag_model = `prop_money_bag_01`,
anim = '_bag_walk_garbage_man',
dict = 'missfbi4prepp1',
flag = 49,
bone = 57005,
posx = 0.35,
posy = -0.25,
posz = -0.15,
rotx = 220.0,
roty = 120.0,
rotz = 0.0
}
Config.TakeBagSettings = {
dict = 'anim@gangops@facility@servers@',
anim = 'hotwire',
flag = 16,
}
Config.GuardJobBlipSettings = {
sprite = 487,
color = 3,
scale = 1.0,
label = "Target Location",
}
Config.GuardJobPedModels = {
["casinomodels"] = {
"s_m_m_movprem_01",
"s_m_y_casino_01",
"csb_tomcasino",
"cs_milton",
"u_f_m_promourn_01",
"u_f_m_casinocash_01",
"u_f_m_casinoshop_01",
},
["pacificbank"] = {
"s_m_m_fiboffice_02",
"cs_bankman",
"u_f_m_miranda",
"a_f_y_business_01",
},
["judge"] = {
"csb_reporter",
"cs_paper",
"a_f_y_femaleagent",
},
["governor"] = {
"s_m_m_highsec_02",
"cs_fbisuit_01",
"s_f_m_shop_high",
},
["businessman"] = {
"s_m_m_mariachi_01",
"s_m_m_strpreach_01",
"cs_movpremmale",
"u_f_o_moviestar",
"u_f_y_jewelass_01",
"a_f_y_business_04",
},
}
```
lang.lua
```lua
LANG = {
store_vehicle = "[E] Store Vehicle",
garage_key = "[E]",
impounded_garage_interaction = "[E] Impounded Garage",
vehicle_not_found = "Garage Not Have Any Vehicle",
store_error = "You can't leave this car in this garage",
water_fill = "Filling Up The Water",
water_drinking = "Drinking ...",
coffe_drinking = "Drinking ...",
printer_busy = "Printer Busy Now!",
printer_menu_label = "Print Document",
printer_menu_url = "URL",
printer_menu_url_description = "Please Enter Correct Url",
printer_process = "Printing ...",
no_found_item_for_repair = "Not Found Any Item For Repair!",
coffe_machine_used_anyone = "The coffee machine is being used by someone else!",
coffe_item_error = "You don't have the necessary things to make coffee!",
stored_vehicle = "Vehicle is stored, Plate : %s",
in_test_drive = "You are already on a test drive",
test_drive_end = "Test Drive End!",
test_drive_remaining_time = "Remaining time : %s seconds!",
vehicle_buyed = "Vehicle Succesffuly Buyed!",
no_money_error = "Not Enough Money In Your Company Safe!",
vehicle_already_outside = "Vehicle Already Outside!",
car_spawned = "Vehicle Taked!",
security_card_removed = "Security Card Removed!",
security_card_not_active = "Security Card Deactivated!",
security_card_show_players_desc = "Click For Show This Player!",
security_card_menu_header = "Show ID Card",
security_card_menu_self = "Show My Self",
item_not_found = "Item Not Found!",
-- Garage
garage_menu_header = "MW Garage",
garage_menu_arg_plate = "Plate : %s | Click For Take Car",
garage_menu_arg_plate_outside = "Plate : %s | This Vehicle Impounded!",
-- Impound
no_impounded_vehicle = "Not Found Any Impounded Vehicle!",
take_vehicle_from_impounded = "Click to send the vehicle to the garage!",
impouned_menu_label = "Impounded Garage",
vehicle_taked_from_impounded_garage = "Vehicle Taked From Impounded Garage!",
-- Medical Storage
some_items_not_have_stock = "You couldn't get some items Jul because they weren't in stock",
-- Door
you_dont_have_security_card = "You Don't have Security Card!",
-- Order
order_already_active = "Shipment Already Active!",
order_company_safe_error = "There is not enough money in the company safe!",
order_shipment_succesfully = "The Order was Successfully Created!",
-- Discord
discord_bot_name = 'Wert Merryweather',
qb_input_confirm = "Confirm",
-- Repair
weapon_repair_process = "Repair Process ...",
repair_requid_items_error = "You Dont Have Requid Items!",
-- Jobs
you_already_have_a_active_job = "You Already Have A Active Job!",
merryweather_jobs_menu = "Pending Jobs",
click_for_start_job = "Click Here To Start Job Ready",
job_already_maked = "Job Already Maked!",
job_time_not_coming = "The Hour Has Not Yet Come",
money_transfer_job_started = "The job was taken. A car full of money is waiting for you downstairs. After taking the car and getting into the driver's seat, you need to distribute bags of money to the banks marked on the GPS. Be careful while doing this task, you may be attacked. After making the delivery to the necessary banks, a location will be determined to deliver the vehicle, deliver the vehicle and deposit your money in the company safe. May it come easy, good luck!",
interaction_open_door = "[E] Open Boot Doors",
interaction_start_transfer = "[E] Take Money Bag",
vehicle_doors_opened = "Vehicle Boot Door Opened!",
interaction_deliver_bag = "[E] Deliver the bag",
bag_delivering = "Bag Deliver Process ...",
job_cancelled = "Job Cancelled!",
new_bank_marked_on_map = "This Bank's Business Is OK, The Other Bank Has Been Flagged, Go To It",
money_transfer_finish_go_put_vehicle = "Deliveries Are Completed Deliver The Vehicle And Get Your Money",
money_transfer_finish_succesfful = "Money Transfer Delivery Finish Succesfully. Your Money Deposit Your Company Case!",
license_patent = "Merryweather © 2023 All rights reserved",
money_transfer_job_information_header = '<i class="fa-solid fa-circle-info"></i> Money Transfer Job',
guard_job_information_header = '<i class="fa-solid fa-circle-info"></i> Security Important People Job (Guard)',
money_transfer_take_bag = 'The Bag Is Being Taken ...',
guard_npc_exit_vehicle = "The boss is getting ready to get out of the vehicle, please be careful, ensure security!",
guard_job_cancelled = "The Job Has Been Canceled, the Boss Is Not Safe!",
guard_job_finish_succesfful = "Protection has Been Successfully Achieved Has Reached the Destination Destination Your Money has been Deposited in the Company Vault!",
guard_casino_mid = "The casino manager has been feeling agitated lately and has requested protection from you because of this. If you take the manager safely to the specified location, the money will be deposited in the company's safe when the work is completed. Your car is ready outside and the manager is waiting next to the car. When you get in the car, the manager will follow you.",
guard_pacificbank_mid = "The manager of the Pacific bank has been threatened by thieves recently. He offered you a job to provide security, and you accepted. You must take him safely to the bank and protect him. If harm comes to him, the business will fail. He is waiting outside with the car to take him to the location indicated in the GPS. The money will be deposited into the company's safe at the end of the job. Good luck....",
guard_judge_mid = "The judge needs protection. You need to get him safely to the palace of justice. He is waiting for you outside with the car. Good luck...",
guard_governor_mid = "The governor is in danger according to information provided by intelligence recently. He bought an extra security service to increase security. An armored vehicle is waiting for you downstairs. Take him safely to his office, and when the job is done, you'll get your money delivered.",
guard_businessman_mid = "A famous businessman has important business meetings abroad. He bought a private security service to go to the airport, train him safely to the airport. When the job is completed successfully, you will receive your money.",
-- UI Lang
coffe_machine_ready = "READY!",
coffe_machine_wait = 'WAITING...',
vehicleshop_details_button = "Details",
vehicleshop_line_adress = "Merryweather.com/Vehicleshop",
vehicleshop_breaking = "Breaking",
vehicleshop_Acceleration = "Acceleration",
vehicleshop_topspeed = "Max Speed",
vehicleshop_Traction = "Traction",
vehicleshop_vehicle_color = "VEHICLE COLOR",
vehicleshop_button_testdrive = "Test Drive",
vehicleshop_button_buy = "Buy",
repair_menu_click_text = "Click For Repair!",
repair_requid_items_header = "REQUID ITEMS",
repair_requid_info_name = "NAME",
repair_requid_info_needed = "NEEDED",
repair_requid_info_own = "OWN",
repair_button_repair = "REPAIR",
repair_button_close = "CLOSE",
idcard_cardno_label = "Card No",
idcard_blood_label = "Blood",
idcard_email_label = "E-Mail",
idcard_phone_label = "Phone",
idcard_patent = "Los Santos Merryweather Business",
idcard_creator_found_header = "Your Active Card Was Found",
idcard_creator_found_text = "You can't get a new card right now because you have an active card. If you want, you can delete your old card from the button below and then create a new card",
idcard_creator_found_delete_button = "Delete Active Card",
idcard_creator_found_cancel_button = "Cancel",
idcard_creator_create_header = "Create A New Security Card",
idcard_creator_create_pp = "Personel Image",
idcard_createor_create_pp_placeholder = "Enter Your E-Mail",
idcard_creator_create_mailurl = "@gmail.com",
idcard_creator_create_takephoto = "Take Photo",
idcard_create_create_confirm = "Confirm",
idcard_create_create_cancel = "Cancel",
idcard_create_create_maillabel = "E-Mail",
idcard_create_create_phone_placeholder = "Enter Your Phone Number",
idcard_create_create_phone_label = "Phone Number",
idcard_create_create_blood_label = "Blood Type",
idcard_create_create_rank = "Rank",
idcard_create_create_name = "Name",
idcard_create_image_url_text_placeholder = "Image URL",
shipment_basket_total = "Total :",
shipment_menu_buy_amount = "Buy Amount",
shipment_menu_header = "Create An Order",
shipment_basket_label = "Basket",
shipment_menu_clearall = "Clear All",
shipment_menu_buy = "Buy",
shipment_tracking_header = "Shipment Tracking",
shipment_prepare_label = "Preparing An Order",
shipment_skipped = "This Step Was Skipped",
shipment_cargo_ontheway = "The Cargo Is On Its Way",
shipment_this_step_info = "This Step Is Not Appropriate Right Now",
shipment_In_Distribution = "In Distribution",
shipment_waiting_distribution = "Waiting For Distribution",
shipment_cargo_in_distribution = "It Will Stand By Until The Courier Arrives",
shipment_products_on_company = "Your Products Are on the Right Path to Your Company",
shipment_ontheway_text = "It is Expected to Be at the Port in %s Minutes and %s Seconds",
shipment_prepare_text = "The Order Will Depart After %s Minutes and %s Seconds",
medical_storage_label = "Medical Storage",
medical_storage_basket_label = "Basket",
medical_storage_clear_basket = "Clear All",
medical_storage_confirm_basket = "Confirm",
weapon_storage_label = "Weapon Storage",
weapon_storage_basket_label = "Basket",
weapon_storage_clear_basket = "Clear All",
weapon_storage_confirm_basket = "Confirm",
}
```
editable_client file
local QBCore = exports['qb-core']:GetCoreObject()
-- # Functions
function Draw2DText(content, font, colour, scale, x, y)
SetTextFont(font)
SetTextScale(scale, scale)
SetTextColour(colour[1],colour[2],colour[3], 255)
SetTextEntry("STRING")
SetTextDropShadow(0, 0, 0, 0,255)
SetTextDropShadow()
SetTextEdge(4, 0, 0, 0, 255)
SetTextOutline()
AddTextComponentString(content)
DrawText(x, y)
end
function CustomNotif(text, style, time)
QBCore.Functions.Notify(text, style, time)
end
function ShowTextUI(text)
if Config.OxLib then
lib.showTextUI(text, {position = 'left-center'})
else
exports['qb-core']:DrawText(text, 'left')
end
end
function HideTextUI()
if Config.OxLib then
lib.hideTextUI()
else
exports['qb-core']:HideText()
end
end
function SetFuelAddonExport(vehicle, fuel)
-- If you use another fuel system you can edit here
if GetResourceState('LegacyFuel') == 'started' then exports['LegacyFuel']:SetFuel(vehicle, fuel) end
end
function GetFuelAddonExport(vehicle)
-- If you use another fuel system you can edit here
if GetResourceState('LegacyFuel') == 'started' then
local totalFuel = exports['LegacyFuel']:GetFuel(vehicle)
return totalFuel
else return 100 end
end
function CustomTargetAddBoxZone(data, options)
exports["qb-target"]:AddBoxZone(data.name, data.coord, data.sizeA, data.sizeB, {
name = data.name,
heading = data.heading,
debugPoly = Config.DebugPoly,
minZ = data.minZ,
maxZ = data.maxZ
}, {
options = options,
distance = 1.5
})
end
function TakePhoto(hook, cb)
if GetResourceState('screenshot-basic') == 'started' then
hook = tostring(hook)
if hook then
exports['screenshot-basic']:requestScreenshotUpload(tostring(hook), "files[]", function(data)
local image = json.decode(data)
local url = image.attachments[1].proxy_url
cb(url)
end)
else cb("") end
else cb("") end
end
function LoadDoorTargets()
for i=1, #Config.DoorTargets do
local row = Config.DoorTargets[i]
local name = row.door_id .. "_MerryweatherDoor_" .. i
exports["qb-target"]:AddBoxZone(name, row.coord, row.width, row.length, {
name = name,
heading = row.heading,
debugPoly = Config.DebugPoly,
minZ = row.minZ,
maxZ = row.maxZ
}, {
options = {
{
type = "client",
event = "wert-merryweather:client:door-action",
icon = row.icon,
label = row.label,
job = row.job,
targeticon = row.targeticon,
door_id = row.door_id
},
},
distance = 1.5
})
end
end
function CustomOxProgressBar(data)
return lib.progressCircle(data)
end
-- # Events
RegisterNetEvent('wert-merryweather:client:notif', function(text, style, time)
CustomNotif(text, style, time)
end)
RegisterNetEvent('wert-merryweather:client:stash', function()
if Config.OxInventory then
local ox_inventory = exports.ox_inventory
ox_inventory:openInventory('stash', 'MerryweatherStash_1')
else
TriggerEvent("inventory:client:SetCurrentStash", "MerryweatherStash_1")
TriggerServerEvent("inventory:server:OpenInventory", "stash", "MerryweatherStash_1", {
maxweight = 2000000,
slots = 40,
})
end
end)
RegisterNetEvent('wert-merryweather:client:custom-status', function(status, amount)
local pdata = QBCore.Functions.GetPlayerData()
if status == "thirst" then
TriggerServerEvent("QBCore:Server:SetMetaData", "thirst", pdata.metadata.thirst + amount)
elseif status == "hunger" then
TriggerServerEvent("QBCore:Server:SetMetaData", "hunger", pdata.metadata.hunger + amount)
end
end)
RegisterNetEvent('wert-merryweather:client:give-keys-addon', function(vehicle, plate)
TriggerEvent("vehiclekeys:client:SetOwner", plate)
end)
RegisterNetEvent('wert-merryweather:client:bossmenu', function()
-- If you use any different bossmenu change open event here
TriggerEvent('qb-bossmenu:client:OpenMenu') -- qb-management
end)
RegisterNetEvent('wert-merryweather:client:custom-door-event', function(id, state)
-- You need edit for your door script
end)
editable_server file
local QBCore = exports['qb-core']:GetCoreObject()
local WEBHOOK = ""
local DiscordLogWebhook = ""
SecurityCards = {}
if Config.OxInventory then
local ox_inventory = exports.ox_inventory
local stash = {
id = 'MerryweatherStash_1',
label = 'MerryweatherStash 1',
slots = 40,
weight = 2000000,
}
ox_inventory:RegisterStash(stash.id, stash.label, stash.slots, stash.weight)
end
function GetSocietyMoney()
local amount = exports['qb-management']:GetAccount(Config.SocietyName)
return amount or 0
end
function RemoveSocietyMoney(amount)
exports['qb-management']:RemoveMoney(Config.SocietyName, amount)
end
function AddSocietyMoney(amount)
exports['qb-management']:AddMoney(Config.SocietyName, amount)
end
-- If your Config.DiscordLog = true | Discord log work
function DiscordLog(title, message)
local embedData = {
{
['title'] = title,
['color'] = '65280',
['footer'] = {
['text'] = os.date('%c'),
},
['description'] = message,
['author'] = {
['name'] = LANG.discord_bot_name,
['icon_url'] = 'your_url.png',
},
}
}
PerformHttpRequest(DiscordLogWebhook, function() end, 'POST', json.encode({ username = LANG.discord_bot_name, embeds = embedData}), { ['Content-Type'] = 'application/json' })
end
-- # Events
RegisterNetEvent('wert-merryweather:server:printed', function(url)
local src = source
local ply = QBCore.Functions.GetPlayer(src)
if not ply then return end
local info = {}
info.photourl = url
ply.Functions.AddItem(Config.PrinterItemName, 1, false, info)
TriggerClientEvent('inventory:client:ItemBox', src, QBCore.Shared.Items[Config.PrinterItemName], 'add')
end)
RegisterNetEvent('wert-merryweather:server:repair-weapon', function(name, slot)
local src = source
local ply = QBCore.Functions.GetPlayer(src)
if not ply then return end
if Config.OxInventory then
exports.ox_inventory:SetDurability(src, slot, 100)
else
local WeaponSlot = ply.PlayerData.items[slot]
if not WeaponSlot then return end
if WeaponSlot.info then
WeaponSlot.info.quality = 100
else
WeaponSlot.info = {}
WeaponSlot.info.quality = 100
end
ply.Functions.SetInventory(ply.PlayerData.items, true)
end
end)
-- # Callbacks
QBCore.Functions.CreateCallback("wert-merryweather:server:photo-webhook", function(source, cb)
cb(WEBHOOK)
end)
-- # Items
QBCore.Functions.CreateUseableItem(Config.CoffeItem , function(source, item)
TriggerClientEvent("wert-merryweather:client:use-coffe-item", source)
end)
if not Config.OxInventory then
QBCore.Functions.CreateUseableItem(Config.PrinterItemName, function(source, item)
if item and item.info and item.info.photourl then
TriggerClientEvent("wert-merryweather:client:use-printer-docs", source, item.info.photourl)
else
print("Documention Data Not Found!")
end
end)
QBCore.Functions.CreateUseableItem(Config.IdCardItemName, function(source, item)
if item and item.info and item.info.cardno then
if SecurityCards[item.info.cardno] then
TriggerClientEvent("wert-merryweather:client:use-idcard", source, item.info)
else
TriggerClientEvent('wert-merryweather:client:notif', source, LANG.security_card_not_active, "error")
end
end
end)
else
RegisterNetEvent('wert-merryweather:server:use-idcard-item-oxinv', function(info)
local src = source
if SecurityCards[info.cardno] then
TriggerClientEvent("wert-merryweather:client:use-idcard", src, info)
else
TriggerClientEvent('wert-merryweather:client:notif', src, LANG.security_card_not_active, "error")
end
end)
-- Make This Steps For Add in your useable list
-- Go This location ox_inventory/modules/items/client.lua
-- Add this codes
--[[ Item('merryweather_documention', function(data, slot)
local metadata = slot.metadata
if not metadata or not metadata.photourl then return end
TriggerEvent("wert-merryweather:client:use-printer-docs", metadata.photourl)
end)
Item('merryweather_idcard', function(data, slot)
local metadata = slot.metadata
if not metadata or not metadata.cardno then return end
TriggerServerEvent("wert-merryweather:server:use-idcard-item-oxinv", metadata)
end) ]]
end
FINISH
Last updated