Police siren can be heard from mechanic vehicle at long distance (lightbar only)

Hi everyone,

I’m having a strange issue on our FiveM server.

We have a mechanic vehicle that only has a lightbar. The lightbar can be toggled on and off with the E key, and the vehicle does not have a siren.

However, when the lightbar is turned on and the mechanic vehicle drives away, at a certain distance a police siren suddenly becomes audible, even though no siren is active. As soon as the vehicle gets closer again, the siren disappears.

It seems like the game starts playing a distant emergency vehicle siren instead of just rendering the lightbar.

Has anyone experienced this before or knows what could cause it? Is there a way to prevent the distant police siren from playing on vehicles that only use emergency lights?

Any help would be greatly appreciated. Thanks!

At some point, either you optimized the resource that is handling sirens or installed a resource that tried to optimize them.

Try to look for something handling DistantCopCarSirens. This happened to us when we refactored/optimized LVC, leading to “ghost sirens” like you’re describing.

CreateThread(function()
    while true do
        Wait(16)
        --- This needs to be continually set or else an emergency vehicle can get in such a state that it continually plays these sirens.
        DistantCopCarSirens(false)
    end

we found 16 ms “enough” that players can’t hear the ghost siren, if you’re using LVC you just have to take a performance hit on this unfortunately.

Thanks, I’ve inserted it like that. It works!