📝Configuration
This page contains an example of a configuration file.
cfx-praryo-deathcam/configs/cl_config.lua
--==============================================================
-- The configs written here are basically client-sided configs.
--==============================================================
CLConfig = {}
--@config Duration in milliseconds of the death camera.
CLConfig.Duration = 5000
--@config Command to force close active death cam UI through F8. Set to "" or nil to disable.
CLConfig.ForceCloseCommand = "closeDeathCam"
--@config View death cam report keybind. Set to "" or nil to disable.
CLConfig.ViewDeathCamKey = "H"
--@config Notification UI design
CLConfig.ViewDeathCamTextUI = {
position = "right-center",
icon = 'info',
}
cfx-praryo-deathcam/configs/sv_config.lua
--=========================================================
-- The configs written here are hidden from humpy dumpers.
--=========================================================
SVConfig = {}
--@config Discord bot token if you want to use discord avatars
SVConfig.DiscordBotToken = ""
--@config framework (First & Last Name) / fivem (GetPlayerName) / discord (Discord Username)
SVConfig.PlayerNameType = "framework"
--@config discord (Discord Avatar) / custom (SVConfig.CustomAvatars)
SVConfig.PlayerAvatarType = "discord"
--@config Custom player avatars linked to identifier.
SVConfig.CustomAvatars = {
-- ["DEQ74212"] = "https://imgur.com/donut.png" -- QBCore / QBX Example.
-- ["6ab98f9723e0f0fc875e6253e8bd5dc64fb33185"] = "https://imgur.com/donut.png" -- ESX Example.
-- ["char1:6ab98f9723e0f0fc875e6253e8bd5dc64fb33185"] = "https://imgur.com/donut.png" -- ESX Multicharacter Example.
-- ["standalone_identifier"] = "https://imgur.com/donut.png" -- Standalone Example. (Identifier comes from SVConfig.StandaloneFunctions["FetchPlayerIdentifier"](source))
}
--@config Custom player background linked to identifier.
SVConfig.CustomBackground = {
-- ["DEQ74212"] = "https://imgur.com/donut.png" -- QBCore / QBX Example.
-- ["6ab98f9723e0f0fc875e6253e8bd5dc64fb33185"] = "https://imgur.com/donut.png" -- ESX Example.
-- ["char1:6ab98f9723e0f0fc875e6253e8bd5dc64fb33185"] = "https://imgur.com/donut.png" -- ESX Example.
-- ["standalone_identifier"] = "https://imgur.com/donut.png" -- Standalone Example. (Identifier comes from SVConfig.StandaloneFunctions["FetchPlayerIdentifier"](source))
}
--@config Custom player banner linked to identifier.
SVConfig.CustomBanner = {
-- ["DEQ74212"] = "https://imgur.com/donut.png" -- QBCore / QBX Example.
-- ["6ab98f9723e0f0fc875e6253e8bd5dc64fb33185"] = "https://imgur.com/donut.png" -- ESX Example.
-- ["char1:6ab98f9723e0f0fc875e6253e8bd5dc64fb33185"] = "https://imgur.com/donut.png" -- ESX Multicharacter Example.
-- ["standalone_identifier"] = "https://imgur.com/donut.png" -- Standalone Example. (Identifier comes from SVConfig.StandaloneFunctions["FetchPlayerIdentifier"](source))
}
--@config Custom player badges linked to identifiers.
--@config Icons URL: https://lucide.dev/icons/
--@config Icons color URL: https://tailwindcss.com/docs/text-color
SVConfig.Badges = {
[1] = {
id = "developer",
label = "Developer",
icon = "Code2",
icon_color = "text-green-500",
has_access = function(source)
local ESX = getFrameworkObject()
local xPlayer = ESX.GetPlayerFromId(source)
--@return value should be in boolean.
return xPlayer.getGroup() == "developer"
end
},
}
--================================================================================================
-- Below is the standalone server functions that you can freely modify to your custom framework.
--================================================================================================
SVConfig.StandaloneFunctions = {
--@function Fetch player name.
--@param source
["FetchPlayerName"] = function(source)
-- Put your custom framework / standalone statements here.
return GetPlayerName(source)
end,
--@function Fetch player identifiers just in case you use other identifier on your framework.
--@param source
["FetchPlayerIdentifier"] = function(source)
-- Put your custom framework / standalone statements here.
return "license:123456789"
end
}
cfx-praryo-deathcam/configs/sh_config.lua
--===================================================================
-- Frameworks are detected automatically.
-- Supported frameworks: ESX, QBCore, Standalone / Custom Framework
--===================================================================
-- @overextended locales. (DO NOT REMOVE!!)
lib.locale()
SHConfig = {}
--@config Enable / disable debugging mode.
SHConfig.Debug = true
--@config Force standalone mode, resource will no longer detect frameworks automatically.
SHConfig.ForceStandalone = false
--@config Framework resource name.
SHConfig.Frameworks = {
["esx"] = "es_extended",
["qb"] = "qb-core",
["qbx"] = "qbx-core",
}
--@config Weapon names for fetching weapon image URL.
SHConfig.WeaponsNames = {
[-1075685676] = "WEAPON_PISTOL_MK2",
[126349499] = "WEAPON_SNOWBALL",
[-270015777] = "WEAPON_ASSAULTSMG",
[615608432] = "WEAPON_MOLOTOV",
[2024373456] = "WEAPON_SMG_MK2",
[-1810795771] = "WEAPON_POOLCUE",
[-1813897027] = "WEAPON_GRENADE",
[-598887786] = "WEAPON_MARKSMANPISTOL",
[-1654528753] = "WEAPON_BULLPUPSHOTGUN",
[-72657034] = "GADGET_PARACHUTE",
[-102323637] = "WEAPON_BOTTLE",
[2144741730] = "WEAPON_COMBATMG",
[-1121678507] = "WEAPON_MINISMG",
[-1652067232] = "WEAPON_SWEEPERSHOTGUN",
[961495388] = "WEAPON_ASSAULTRIFLE_MK2",
[-86904375] = "WEAPON_CARBINERIFLE_MK2",
[-1786099057] = "WEAPON_BAT",
[177293209] = "WEAPON_HEAVYSNIPER_MK2",
[600439132] = "WEAPON_BALL",
[1432025498] = "WEAPON_PUMPSHOTGUN_MK2",
[-1951375401] = "WEAPON_FLASHLIGHT",
[171789620] = "WEAPON_COMBATPDW",
[1593441988] = "WEAPON_COMBATPISTOL",
[-2009644972] = "WEAPON_SNSPISTOL_MK2",
[2138347493] = "WEAPON_FIREWORK",
[1649403952] = "WEAPON_COMPACTRIFLE",
[-619010992] = "WEAPON_MACHINEPISTOL",
[-952879014] = "WEAPON_MARKSMANRIFLE",
[317205821] = "WEAPON_AUTOSHOTGUN",
[-1420407917] = "WEAPON_PROXMINE",
[-1045183535] = "WEAPON_REVOLVER",
[94989220] = "WEAPON_COMBATSHOTGUN",
[-1658906650] = "WEAPON_MILITARYRIFLE",
[1198256469] = "WEAPON_RAYCARBINE",
[2132975508] = "WEAPON_BULLPUPRIFLE",
[1627465347] = "WEAPON_GUSENBERG",
[984333226] = "WEAPON_HEAVYSHOTGUN",
[1233104067] = "WEAPON_FLARE",
[-1716189206] = "WEAPON_KNIFE",
[940833800] = "WEAPON_STONE_HATCHET",
[1305664598] = "WEAPON_GRENADELAUNCHER_SMOKE",
[727643628] = "WEAPON_CERAMICPISTOL",
[-1074790547] = "WEAPON_ASSAULTRIFLE",
[-1169823560] = "WEAPON_PIPEBOMB",
[324215364] = "WEAPON_MICROSMG",
[-1834847097] = "WEAPON_DAGGER",
[-1466123874] = "WEAPON_MUSKET",
[-1238556825] = "WEAPON_RAYMINIGUN",
[-1063057011] = "WEAPON_SPECIALCARBINE",
[1470379660] = "WEAPON_GADGETPISTOL",
[584646201] = "WEAPON_APPISTOL",
[-494615257] = "WEAPON_ASSAULTSHOTGUN",
[-771403250] = "WEAPON_HEAVYPISTOL",
[1672152130] = "WEAPON_HOMINGLAUNCHER",
[338557568] = "WEAPON_PIPEWRENCH",
[1785463520] = "WEAPON_MARKSMANRIFLE_MK2",
[-1355376991] = "WEAPON_RAYPISTOL",
[101631238] = "WEAPON_FIREEXTINGUISHER",
[1119849093] = "WEAPON_MINIGUN",
[883325847] = "WEAPON_PETROLCAN",
[-102973651] = "WEAPON_HATCHET",
[-275439685] = "WEAPON_DBSHOTGUN",
[-1746263880] = "WEAPON_DOUBLEACTION",
[-879347409] = "WEAPON_REVOLVER_MK2",
[125959754] = "WEAPON_COMPACTLAUNCHER",
[911657153] = "WEAPON_STUNGUN",
[-2066285827] = "WEAPON_BULLPUPRIFLE_MK2",
[-538741184] = "WEAPON_SWITCHBLADE",
[100416529] = "WEAPON_SNIPERRIFLE",
[-656458692] = "WEAPON_KNUCKLE",
[-1768145561] = "WEAPON_SPECIALCARBINE_MK2",
[1737195953] = "WEAPON_NIGHTSTICK",
[2017895192] = "WEAPON_SAWNOFFSHOTGUN",
[-2067956739] = "WEAPON_CROWBAR",
[-1312131151] = "WEAPON_RPG",
[-1568386805] = "WEAPON_GRENADELAUNCHER",
[205991906] = "WEAPON_HEAVYSNIPER",
[1834241177] = "WEAPON_RAILGUN",
[-1716589765] = "WEAPON_PISTOL50",
[736523883] = "WEAPON_SMG",
[1317494643] = "WEAPON_HAMMER",
[453432689] = "WEAPON_PISTOL",
[1141786504] = "WEAPON_GOLFCLUB",
[-1076751822] = "WEAPON_SNSPISTOL",
[-2084633992] = "WEAPON_CARBINERIFLE",
[487013001] = "WEAPON_PUMPSHOTGUN",
[-1168940174] = "WEAPON_HAZARDCAN",
[-38085395] = "WEAPON_DIGISCANNER",
[-1853920116] = "WEAPON_NAVYREVOLVER",
[-37975472] = "WEAPON_SMOKEGRENADE",
[-1600701090] = "WEAPON_BZGAS",
[-1357824103] = "WEAPON_ADVANCEDRIFLE",
[-581044007] = "WEAPON_MACHETE",
[741814745] = "WEAPON_STICKYBOMB",
[-608341376] = "WEAPON_COMBATMG_MK2",
[137902532] = "WEAPON_VINTAGEPISTOL",
[-1660422300] = "WEAPON_MG",
[1198879012] = "WEAPON_FLAREGUN",
}
--@config Weapon labels
SHConfig.WeaponLabels = {
[tonumber(`WEAPON_UNARMED`)] = 'Unarmed',
[tonumber(`GADGET_PARACHUTE`)] = 'Parachute',
[tonumber(`WEAPON_KNIFE`)] = 'Knife',
[tonumber(`WEAPON_NIGHTSTICK`)] = 'Nightstick',
[tonumber(`WEAPON_HAMMER`)] = 'Hammer',
[tonumber(`WEAPON_BAT`)] = 'Baseball Bat',
[tonumber(`WEAPON_CROWBAR`)] = 'Crowbar',
[tonumber(`WEAPON_GOLFCLUB`)] = 'Golf Club',
[tonumber(`WEAPON_BOTTLE`)] = 'Bottle',
[tonumber(`WEAPON_DAGGER`)] = 'Antique Cavalry Dagger',
[tonumber(`WEAPON_HATCHET`)] = 'Hatchet',
[tonumber(`WEAPON_KNUCKLE`)] = 'Knuckle Duster',
[tonumber(`WEAPON_MACHETE`)] = 'Machete',
[tonumber(`WEAPON_FLASHLIGHT`)] = 'Flashlight',
[tonumber(`WEAPON_SWITCHBLADE`)] = 'Switchblade',
[tonumber(`WEAPON_BATTLEAXE`)] = 'Battleaxe',
[tonumber(`WEAPON_POOLCUE`)] = 'Poolcue',
[tonumber(`WEAPON_PIPEWRENCH`)] = 'Wrench',
[tonumber(`WEAPON_STONE_HATCHET`)] = 'Stone Hatchet',
[tonumber(`WEAPON_PISTOL`)] = 'Pistol',
[tonumber(`WEAPON_PISTOL_MK2`)] = 'Pistol Mk2',
[tonumber(`WEAPON_COMBATPISTOL`)] = 'Combat Pistol',
[tonumber(`WEAPON_PISTOL50`)] = 'Pistol .50 ',
[tonumber(`WEAPON_SNSPISTOL`)] = 'SNS Pistol',
[tonumber(`WEAPON_SNSPISTOL_MK2`)] = 'SNS Pistol Mk2',
[tonumber(`WEAPON_HEAVYPISTOL`)] = 'Heavy Pistol',
[tonumber(`WEAPON_VINTAGEPISTOL`)] = 'Vintage Pistol',
[tonumber(`WEAPON_MARKSMANPISTOL`)] = 'Marksman Pistol',
[tonumber(`WEAPON_REVOLVER`)] = 'Heavy Revolver',
[tonumber(`WEAPON_REVOLVER_MK2`)] = 'Heavy Revolver Mk2',
[tonumber(`WEAPON_DOUBLEACTION`)] = 'Double-Action Revolver',
[tonumber(`WEAPON_APPISTOL`)] = 'AP Pistol',
[tonumber(`WEAPON_STUNGUN`)] = 'Stun Gun',
[tonumber(`WEAPON_FLAREGUN`)] = 'Flare Gun',
[tonumber(`WEAPON_RAYPISTOL`)] = 'Up-n-Atomizer',
[tonumber(`WEAPON_GLOCK20`)] = 'Glock-20 Pistol',
[tonumber(`WEAPON_MICROSMG`)] = 'Micro SMG',
[tonumber(`WEAPON_MACHINEPISTOL`)] = 'Machine Pistol',
[tonumber(`WEAPON_MINISMG`)] = 'Mini SMG',
[tonumber(`WEAPON_SMG`)] = 'SMG',
[tonumber(`WEAPON_SMG_MK2`)] = 'SMG Mk2 ',
[tonumber(`WEAPON_ASSAULTSMG`)] = 'Assault SMG',
[tonumber(`WEAPON_COMBATPDW`)] = 'Combat PDW',
[tonumber(`WEAPON_MG`)] = 'MG',
[tonumber(`WEAPON_COMBATMG`)] = 'Combat MG ',
[tonumber(`WEAPON_COMBATMG_MK2`)] = 'Combat MG Mk2',
[tonumber(`WEAPON_GUSENBERG`)] = 'Gusenberg Sweeper',
[tonumber(`WEAPON_RAYCARBINE`)] = 'Unholy Deathbringer',
[tonumber(`WEAPON_ASSAULTRIFLE`)] = 'Assault Rifle',
[tonumber(`WEAPON_ASSAULTRIFLE_MK2`)] = 'Assault Rifle Mk2',
[tonumber(`WEAPON_CARBINERIFLE`)] = 'Carbine Rifle',
[tonumber(`WEAPON_CARBINERIFLE_MK2`)] = 'Carbine Rifle Mk2',
[tonumber(`WEAPON_ADVANCEDRIFLE`)] = 'Advanced Rifle',
[tonumber(`WEAPON_SPECIALCARBINE`)] = 'Special Carbine',
[tonumber(`WEAPON_SPECIALCARBINE_MK2`)] = 'Special Carbine Mk2',
[tonumber(`WEAPON_BULLPUPRIFLE`)] = 'Bullpup Rifle',
[tonumber(`WEAPON_BULLPUPRIFLE_MK2`)] = 'Bullpup Rifle Mk2',
[tonumber(`WEAPON_COMPACTRIFLE`)] = 'Compact Rifle',
[tonumber(`WEAPON_SCARH`)] = 'Scar-H Rifle',
[tonumber(`WEAPON_SNIPERRIFLE`)] = 'Sniper Rifle',
[tonumber(`WEAPON_HEAVYSNIPER`)] = 'Heavy Sniper',
[tonumber(`WEAPON_HEAVYSNIPER_MK2`)] = 'Heavy Sniper Mk2',
[tonumber(`WEAPON_MARKSMANRIFLE`)] = 'Marksman Rifle',
[tonumber(`WEAPON_MARKSMANRIFLE_MK2`)] = 'Marksman Rifle Mk2',
[tonumber(`WEAPON_GRENADE`)] = 'Grenade',
[tonumber(`WEAPON_STICKYBOMB`)] = 'Sticky Bomb',
[tonumber(`WEAPON_PROXMINE`)] = 'Proximity Mine',
[tonumber(`WEAPON_PIPEBOMB`)] = 'Pipe Bomb',
[tonumber(`WEAPON_SMOKEGRENADE`)] = 'Tear Gas',
[tonumber(`WEAPON_BZGAS`)] = 'BZ Gas',
[tonumber(`WEAPON_MOLOTOV`)] = 'Molotov',
[tonumber(`WEAPON_FIREEXTINGUISHER`)] = 'Fire Extinguisher',
[tonumber(`WEAPON_PETROLCAN`)] = 'Jerry Can',
[tonumber(`WEAPON_BALL`)] = 'Ball',
[tonumber(`WEAPON_SNOWBALL`)] = 'Snowball',
[tonumber(`WEAPON_FLARE`)] = 'Flare',
[tonumber(`WEAPON_GRENADELAUNCHER`)] = 'Grenade Launcher',
[tonumber(`WEAPON_RPG`)] = 'RPG',
[tonumber(`WEAPON_MINIGUN`)] = 'Minigun',
[tonumber(`WEAPON_FIREWORK`)] = 'Firework Launcher',
[tonumber(`WEAPON_RAILGUN`)] = 'Railgun',
[tonumber(`WEAPON_HOMINGLAUNCHER`)] = 'Homing Launcher',
[tonumber(`WEAPON_COMPACTLAUNCHER`)] = 'Compact Grenade Launcher',
[tonumber(`WEAPON_RAYMINIGUN`)] = 'Widowmaker',
[tonumber(`WEAPON_PUMPSHOTGUN`)] = 'Pump Shotgun',
[tonumber(`WEAPON_PUMPSHOTGUN_MK2`)] = 'Pump Shotgun Mk2',
[tonumber(`WEAPON_SAWNOFFSHOTGUN`)] = 'Sawed-off Shotgun',
[tonumber(`WEAPON_BULLPUPSHOTGUN`)] = 'Bullpup Shotgun',
[tonumber(`WEAPON_ASSAULTSHOTGUN`)] = 'Assault Shotgun',
[tonumber(`WEAPON_MUSKET`)] = 'Musket',
[tonumber(`WEAPON_HEAVYSHOTGUN`)] = 'Heavy Shotgun',
[tonumber(`WEAPON_DBSHOTGUN`)] = 'Double Barrel Shotgun',
[tonumber(`WEAPON_AUTOSHOTGUN`)] = 'Sweeper Shotgun',
[tonumber(`WEAPON_REMOTESNIPER`)] = 'Remote Sniper',
[tonumber(`WEAPON_GRENADELAUNCHER_SMOKE`)] = 'Smoke Grenade Launcher',
[tonumber(`WEAPON_PASSENGER_ROCKET`)] = 'Passenger Rocket',
[tonumber(`WEAPON_AIRSTRIKE_ROCKET`)] = 'Airstrike Rocket',
[tonumber(`VEHICLE_WEAPON_SPACE_ROCKET`)] = 'Orbital Canon',
[tonumber(`VEHICLE_WEAPON_PLANE_ROCKET`)] = 'Plane Rocket',
[tonumber(`WEAPON_STINGER`)] = 'Stinger [Vehicle]',
[tonumber(`VEHICLE_WEAPON_TANK`)] = 'Tank Cannon',
[tonumber(`VEHICLE_WEAPON_SPACE_ROCKET`)] = 'Rockets',
[tonumber(`VEHICLE_WEAPON_PLAYER_LASER`)] = 'Laser',
[tonumber(`VEHICLE_WEAPON_PLAYER_LAZER`)] = 'Lazer',
[tonumber(`VEHICLE_WEAPON_PLAYER_BUZZARD`)] = 'Buzzard',
[tonumber(`VEHICLE_WEAPON_PLAYER_HUNTER`)] = 'Hunter',
[tonumber(`VEHICLE_WEAPON_WATER_CANNON`)] = 'Water Cannon',
[tonumber(`AMMO_RPG`)] = 'Rocket',
[tonumber(`AMMO_TANK`)] = 'Tank',
[tonumber(`AMMO_SPACE_ROCKET`)] = 'Rocket',
[tonumber(`AMMO_PLAYER_LASER`)] = 'Laser',
[tonumber(`AMMO_ENEMY_LASER`)] = 'Laser',
[tonumber(`WEAPON_RAMMED_BY_CAR`)] = 'Rammed by Car',
[tonumber(`WEAPON_FIRE`)] = 'Fire',
[tonumber(`WEAPON_HELI_CRASH`)] = 'Heli Crash',
[tonumber(`WEAPON_RUN_OVER_BY_CAR`)] = 'Run over by Car',
[tonumber(`WEAPON_HIT_BY_WATER_CANNON`)] = 'Hit by Water Cannon',
[tonumber(`WEAPON_EXHAUSTION`)] = 'Exhaustion',
[tonumber(`WEAPON_EXPLOSION`)] = 'Explosion',
[tonumber(`WEAPON_ELECTRIC_FENCE`)] = 'Electric Fence',
[tonumber(`WEAPON_BLEEDING`)] = 'Bleeding',
[tonumber(`WEAPON_DROWNING_IN_VEHICLE`)] = 'Drowning in Vehicle',
[tonumber(`WEAPON_DROWNING`)] = 'Drowning',
[tonumber(`WEAPON_BARBED_WIRE`)] = 'Barbed Wire',
[tonumber(`WEAPON_VEHICLE_ROCKET`)] = 'Vehicle Rocket',
[tonumber(`VEHICLE_WEAPON_ROTORS`)] = 'Rotors',
[tonumber(`WEAPON_AIR_DEFENCE_GUN`)] = 'Air Defence Gun',
[tonumber(`WEAPON_ANIMAL`)] = 'Animal',
[tonumber(`WEAPON_COUGAR`)] = 'Cougar',
}
--@config Bone damages for combat reporting.
--@integer: 1 - head / 2 - body / 3 - lower
SHConfig.Bones = {
[0] = 0,
[31085] = 1,
[31086] = 1,
[39317] = 1,
[57597] = 2,
[23553] = 2,
[24816] = 2,
[24817] = 2,
[24818] = 2,
[10706] = 2,
[64729] = 2,
[11816] = 2,
[45509] = 2,
[61163] = 2,
[18905] = 2,
[4089] = 2,
[4090] = 2,
[4137] = 2,
[4138] = 2,
[4153] = 2,
[4154] = 2,
[4169] = 2,
[4170] = 2,
[4185] = 2,
[4186] = 2,
[26610] = 2,
[26611] = 2,
[26612] = 2,
[26613] = 2,
[26614] = 2,
[58271] = 3,
[63931] = 3,
[2108] = 3,
[14201] = 3,
[40269] = 2,
[28252] = 2,
[57005] = 2,
[58866] = 2,
[58867] = 2,
[58868] = 2,
[58869] = 2,
[58870] = 2,
[64016] = 2,
[64017] = 2,
[64064] = 2,
[64065] = 2,
[64080] = 2,
[64081] = 2,
[64096] = 2,
[64097] = 2,
[64112] = 2,
[64113] = 2,
[36864] = 3,
[51826] = 3,
[20781] = 3,
[52301] = 3,
}
Last updated