Ped shoots double with the aiming animation style

Hi! I changed the pedal aiming style with SetWeaponAnimationOverride native. Everything went as planned, ped changed the animation, but when I was shooting, the shot was fired twice,just like in the video:

Could someone please help? I also include code for this simple script, maybe something needs to be changed

local enabled = false
local default = GetHashKey("Default")
local hillbilly = GetHashKey("Hillbilly")


RegisterCommand("hillbilly", function()
    if enabled == false 
    then
        enabled = true
    else
        enabled = false
    end
end)

Citizen.CreateThread(function()
    while true do
        Citizen.Wait(0)
        if enabled == true 
        then
            SetWeaponAnimationOverride(GetPlayerPed(-1), hillbilly)
        else
            SetWeaponAnimationOverride(GetPlayerPed(-1), default)
        end
    end
end)
1 Like