I have done some testing, and have determined that the CPU load appears to be almost identical whether or not I define EdgeEffectiveness.
This seems like a fairly easy optimization that could be done- if EdgeEffectiveness <> defined, then do not do whatever distance-from-center calculation is normally performed, just apply damage after filtering through the Armor array (or whatever data structure that is- forgive me if my grasp of C++ concepts is pretty cruddy).
Yeah, I know, compared to other things, this is a teensy area of improvement- but when you have literally hundreds of shots impacting in lots of places, that starts to add up very quickly. For NanoBlobs or other mass-combat mods, it'd be nice to take this extra "frill" out and gain that bit of speed, if we want to.
EdgeEffectiveness.
Moderator: Moderators
I don't think Spring uses EdgeEffectiveness; grep can't find it in the sources.
The sources look like a linear falloff. According to http://www.tadesigners.com/guides/Maest ... swtutc.htm, I guess it's like a hardcoded edgeeffectiveness of 0.0.
(Game/GameHelper.cpp::Explosion)
The sources look like a linear falloff. According to http://www.tadesigners.com/guides/Maest ... swtutc.htm, I guess it's like a hardcoded edgeeffectiveness of 0.0.
(Game/GameHelper.cpp::Explosion)