Open
Description
What happened?
CAvoidanceComponent pool is listed as 1300 max items when limit is reached we get a crash
CfxCrashDump_2025_03_15_15_20_22.zip
Expected result
should not crash and allow the max items allowed
Reproduction steps
spawn 1300 + props with avoidance flag you will get a crash
Importancy
Unknown
Area(s)
RedM
Specific version(s)
1491
Additional information
local props = {}
RegisterCommand("testProp", function()
RequestModel("p_plank_caster01x", false) -- has avoidance flag
repeat Wait(0) until HasModelLoaded("p_plank_caster01x")
local coords = GetEntityCoords(PlayerPedId())
for i = 1, 1300 do
local table = CreateObject("p_plank_caster01x", coords.x, coords.y, coords.z, false, false, false, false)
props[#props + 1] = table
end
print("done")
end, false)
--on resource stop
AddEventHandler("onResourceStop", function(resource)
if resource == GetCurrentResourceName() then
for _, prop in ipairs(props) do
DeleteObject(prop)
end
end
end)