Source-1-Games
Source-1-Games copied to clipboard
[TF2] Please remove more entities from being network edicts.
While the previous update that removed point_spotlights from using edicts is amazing, they still unnecessarily use edicts for the entities they create. beam and spotlight_end still use edicts and each point_spotlight creates 1 of each.
So say your map has 50 spotlights they still will use 100 network edicts because of the beam and spotlight_end entities.
As I understand it, beam
is necessary for actually rendering lights to clients — properties on the point_spotlight
such as render color and inputs such as LightOn
/ LightOff
are passed to a networked beam entity for display.
spotlight_end
may be parented to a moving edict so they need to be networked, but non-parented instances of those can be killed once the spotlight positioning is set up.
This was partially addressed in an undocumented change on the 2022-07-29 update — if the spotlight is considered efficient, UTIL_Remove()
now gets called on the m_hSpotlightTarget
(its spotlight_end
) during CPointSpotlight::Activate()
, reducing the number of edicts present on the map after it starts up.
Non-networked point_spotlight
entities are also now removed if they don't have a parentname
or targetname
by the time that function is called.
Cutting the edict count for spotlights in half is good. It would be nice if beam entities that didn't have any inputs on them got removed from being a networked entity so it wouldn't use any edicts since if it's static and isn't going to be toggled on/off then there would be no need to have it networked.