This commit is contained in:
delucecc 2023-10-21 15:18:17 -07:00
parent 05367f4c88
commit 6e2ccd9a9c
3 changed files with 7 additions and 4 deletions

View File

@ -1,9 +1,9 @@
CreateThread(function() CreateThread(function()
local ped = PlayerPedId()
while true do while true do
local ped = PlayerPedId()
if IsControlJustPressed(0, 24) and Config.WeaponList[GetSelectedPedWeapon(ped)] then if IsControlJustPressed(0, 24) and Config.WeaponList[GetSelectedPedWeapon(ped)] then
while IsControlPressed(0, 24) or IsDisabledControlPressed(0, 24) do while IsControlPressed(0, 24) or IsDisabledControlPressed(0, 24) do
DisablePlayerFiring(PlayerId(), true) DisablePlayerFiring(ped, true)
Wait(0) Wait(0)
end end
end end

View File

@ -1,3 +1,5 @@
Config = {}
Config.WeaponList = { Config.WeaponList = {
[`weapon_hkump`] = true, [`weapon_smg`] = true,
} }

View File

@ -14,6 +14,7 @@ client_scripts {
escrow_ignore { escrow_ignore {
"config.lua", "config.lua",
"README.md", "README.md",
'client/*.lua',
} }
lua54 'yes' lua54 'yes'