> For the complete documentation index, see [llms.txt](https://gabjeksuper.gitbook.io/fiveguard-configuration/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gabjeksuper.gitbook.io/fiveguard-configuration/block-expolits/block-crash-methods/before-reading/0x31.md).

# 0x31

Add this function to prevent this crash method&#x20;

* `Game crashed: GTA5_b3258.exe!sub_1411D3FA8 (0x31)`

```lua
local pedCount = {}
local fgname = "fiveguard"
local ban = true

AddEventHandler('entityCreating', function(entity)
    if GetEntityType(entity) ~= 1 then return end
    local src = NetworkGetEntityOwner(entity)
    if not src or src <= 0 then return end
    pedCount[src] = (pedCount[src] or 0) + 1
    if pedCount[src] > 1 then
        CancelEvent()
        if ban then
            exports[fgname]:fg_BanPlayer(src, "Cheater (crash 0x31)", true)
        else
            DropPlayer(src, 'Cheater')
        end
    end
end)
AddEventHandler('playerDropped', function()
    pedCount[source] = nil
end)
```

This function needs to be added **server side**, the **Fiveguard export ban** has **already** been **added**

* Change the name on line two from `"fiveguard"` to the **current name of your fiveguard folder**

***This type of crash has already been fixed by Fiveguard, you just need to update Fiveguard to the latest version***
