by Marisa the Magician » Wed Oct 19, 2022 12:02 am
In custom ZScript code, it's practically become a regular thing that every single call to DamageMobj needs a null check afterwards because some actors will simply stop existing and become null immediately as they have no Death state defined. Some people don't know this, and it ends up causing VM aborts, and it has to be patched up. Besides, something like this makes it difficult to perform other operations afterwards, such as spawning/tracing blood from the actor after it takes damage.
I don't understand why the base Actor class can't just have a simple Death state that's a single TNT1 A 1. Would that cause some sort of problem?
In custom ZScript code, it's practically become a regular thing that every single call to DamageMobj needs a null check afterwards because some actors will simply stop existing and become null immediately as they have no Death state defined. Some people don't know this, and it ends up causing VM aborts, and it has to be patched up. Besides, something like this makes it difficult to perform other operations afterwards, such as spawning/tracing blood from the actor after it takes damage.
I don't understand why the base Actor class can't just have a simple Death state that's a single [c]TNT1 A 1[/c]. Would that cause some sort of problem?