sync lifetime component children

This commit is contained in:
bgkillas 2024-10-10 05:50:24 -04:00
parent 9db95a9cad
commit 8cb11fa91f

View file

@ -17,7 +17,7 @@ function effect_sync.get_ent_effects(entity, perks)
local list = {}
for _, ent in ipairs(EntityGetAllChildren(entity) or {}) do
-- Do not include disabled components here
if EntityHasTag(ent, "projectile") then
if EntityHasTag(ent, "projectile") or EntityGetFirstComponentIncludingDisabled(ent, "LifetimeComponent") ~= nil then
table.insert(list, ent)
else
local com = EntityGetFirstComponent(ent, "GameEffectComponent")