Wreck with self-d
Moderator: Moderators
Wreck with self-d
I'm completely out of it... anyone want to remind me how to make units leave a wreck when then self-d instead of just when they are destroyed?
I'll give a quick overview because I think it's different from TA, and I had never heard of how this worked in spring other than seeing it in the source. Forgive me if you know this.yuritch wrote:Adjust the Killed() BOS function so that it returns a valid corpse for severity=100 (self-d should cause that)?
Whenever a unit is damaged, the damage dealt is added to recentDamage. recentDamage drops 10% each frame. Severity is recentDamage / maxHealth.
Back to the question.
This line is run when a unit self-Ds:
recentDamage += maxHealth * 2;
So severity is whatever it would have been had the unit just dropped dead + 200