This commit is contained in:
Nordi98 2025-07-28 00:09:15 +02:00
parent 4485cc31df
commit 3afa513b4a
22 changed files with 1331 additions and 575 deletions

View file

@ -0,0 +1,206 @@
--[[
- this script needs tgiann-core script to work, you can download the script from your keymaster account
Start tgiann-core script after es_extented/qb-core script and before tgiann-* scripts
Adjust the tgiann-core config file according to the framework you are using

https://tgiann.gitbook.io/tgiann/scripts/tgiann-weapons-on-back

Note: If you want the weapons to be invisible while in Noclip, the character must be completely invisible. If your character is invisible to other players, other players cannot see these weapons.
If you want to edit this, take a look at client/editable.lua
]]

tgiCoreExports = exports["tgiann-core"]
config = tgiCoreExports:getConfig()
config.debug = false

config.tgiann_attachments = GetResourceState("tgiann-attachment") ~= "missing" -- https://tgiann.tebex.io/package/5399235

-- Weapon positions for male and female characters. You can add additional positions here if you like.
config.positions = {
male = {
back = { -- We have set 3 positions for the back. You can add or remove extra positions if you like. This setting also applies to other positions.
{ -- position 1
bone = 24816,
offset = vector3(0.285, -0.17, 0.13),
rot = vector3(0.0, 170.0, 0.0),
},
{ -- position 2
bone = 24816,
offset = vector3(0.285, -0.17, 0.0),
rot = vector3(0.0, 170.0, 0.0),
},
{ -- position 3
bone = 24816,
offset = vector3(0.285, -0.17, -0.13),
rot = vector3(0.0, 170.0, 0.0),
}
},
front = {
{
bone = 24818,
offset = vector3(-0.03, 0.19, 0.0),
rot = vector3(-10.0, 40.0, 5.0),
}
},
right = {
{
bone = 11816,
offset = vector3(-0.01, 0.02, 0.215),
rot = vector3(-100.0, 60.0, 45.0),
}
},
rLegBack = {
{
bone = 11816,
offset = vector3(-0.15, -0.11, 0.22),
rot = vector3(0.0, 95.0, 180.0),
}
},
waist = {
{
bone = 11816,
offset = vector3(-0.07, -0.13, 0.05),
rot = vector3(180.0, -30.0, 10.0),
}
},
-- You can add extra positions here if you like.
-- The positions you add can be used in the `config.weaponPositions`, `config.weaponGroupPositions` and `config.weaponGroupJobPositions` settings.
--[[ exampleCustomName = {
{
bone = 11816,
offset = vector3(-0.07, -0.13, 0.05),
rot = vector3(180.0, -30.0, 10.0),
}
}, ]]
},
female = {
back = {
{
bone = 24816,
offset = vector3(0.285, -0.15, 0.13),
rot = vector3(0.0, 170.0, 0.0),
},
{
bone = 24816,
offset = vector3(0.285, -0.15, 0.0),
rot = vector3(0.0, 170.0, 0.0),
},
{
bone = 24816,
offset = vector3(0.285, -0.15, -0.13),
rot = vector3(0.0, 170.0, 0.0),
}
},
front = {
{
bone = 24818,
offset = vector3(-0.03, 0.21, 0.0),
rot = vector3(-10.0, 40.0, 5.0),
}
},
right = {
{
bone = 11816,
offset = vector3(-0.09, 0.03, 0.18),
rot = vector3(-105.0, 75.0, 45.0),
}
},
rLegBack = {
{
bone = 11816,
offset = vector3(-0.15, -0.11, 0.22),
rot = vector3(0.0, 95.0, 180.0),
}
},
waist = {
{
bone = 11816,
offset = vector3(-0.07, -0.09, 0.05),
rot = vector3(180.0, -30.0, 10.0),
}
}
}

}

-- Weapons in the list do not appear on the character
config.disabledWeapons = {
weapon_flashlight = true,
weapon_knuckle = true,
weapon_bottle = true,
weapon_snowball = true,
}

-- adjusts the location of the weapon regardless of its group
config.weaponPositions = {
--weapon_pistol = "right",
}

-- adjusts the position of the weapon regardless of its group
config.weaponCustomPositions = {
male = {
weapon_bat = {
bone = 24816,
offset = vector3(0.0, -0.15, 0.03),
rot = vector3(0.0, 80.0, 0.0),
}
},
female = {
weapon_bat = {
bone = 24816,
offset = vector3(0.0, -0.15, 0.03),
rot = vector3(0.0, 80.0, 0.0),
}
}
}

--"waist" - "back" - "front" - "rigt" - "rLegBack" - "none"
config.weaponGroupPostions = {
[3539449195] = "back", --GROUP_DIGISCANNER
[-37788308] = "rLegBack", --GROUP_FIREEXTINGUISHER
[1175761940] = "none", --GROUP_HACKINGDEVICE
[2725924767] = "back", --GROUP_HEAVY
[-728555052] = "back", --GROUP_MELEE
[3759491383] = "none", --GROUP_METALDETECTOR
[1159398588] = "back", --GROUP_MG
[3493187224] = "none", --GROUP_NIGHTVISION
[431593103] = "none", --GROUP_PARACHUTE
[1595662460] = "none", --GROUP_PETROLCAN
[416676503] = "waist", --GROUP_PISTOL
[970310034] = "back", --GROUP_RIFLE
[860033945] = "back", --GROUP_SHOTGUN
[-957766203] = "front", --GROUP_SMG
[-1212426201] = "back", --GROUP_SNIPER
[690389602] = "none", --GROUP_STUNGUN
[1548507267] = "none", --GROUP_THROWN
[75159441] = "back", --GROUP_TRANQILIZER
[2685387236] = "none", --GROUP_UNARMED
}

-- weapon locations for jobs
config.weaponGroupJobPostions = {
{
jobs = { "police" }, -- u can add multible job name
postions = {
[3539449195] = "back", --GROUP_DIGISCANNER
[-37788308] = "rLegBack", --GROUP_FIREEXTINGUISHER
[1175761940] = "none", --GROUP_HACKINGDEVICE
[2725924767] = "back", --GROUP_HEAVY
[-728555052] = "back", --GROUP_MELEE
[3759491383] = "none", --GROUP_METALDETECTOR
[1159398588] = "back", --GROUP_MG
[3493187224] = "none", --GROUP_NIGHTVISION
[431593103] = "none", --GROUP_PARACHUTE
[1595662460] = "none", --GROUP_PETROLCAN
[416676503] = "right", --GROUP_PISTOL
[970310034] = "back", --GROUP_RIFLE
[860033945] = "back", --GROUP_SHOTGUN
[-957766203] = "front", --GROUP_SMG
[-1212426201] = "back", --GROUP_SNIPER
[690389602] = "none", --GROUP_STUNGUN
[1548507267] = "none", --GROUP_THROWN
[75159441] = "back", --GROUP_TRANQILIZER
[2685387236] = "none", --GROUP_UNARMED
}
}
}