via http://www.chronocrash.com/forum/ind...;topicseen#new

Previously un-typed damage applied by engine is now defined with attack types:


  • ATK_LIFESPAN: Damage used to kill entity at end lifespan.
  • ATK_PIT: Damage used to kill entity that falls below PIT_DEPTH (iow, falls into a pit).
  • ATK_TIMEOVER: Damage used to kill entity when level timer reaches 0.
  • ATK_LAND: Damage received from default THROW animation, Damage on Landing attack parameter, and scripted Damage on Landing property.


Note that ATK_LAND is included in “Defense All”, whereas the other types are not. You can still set Defense for each of the others individually if you like, and yes that means you could make a character immune to its own lifespan, the level timer and even pits! Obviously this could cause some very weird behavior though, so make sure you know what you're doing.

A few uses would be:


  • Regulating damage given by or taken from certain throws and slams. As Damage on Landing was previously untyped, it would simply bypass Offense and Defense settings.
  • Detecting death by pits, the timer or lifespan. It was doable before, but will be a bit simpler now.
  • Other specialized effects, like perhaps an enemy that climbs up out of a pit if thrown in.


A quick technical note for anyone thinking of scripting some of the latter: When the engine attempts to kill an entity due to pits, timer or lifespan the default damage applied = current health.

One last thing. It has been a while since I've been under the hood so to speak, so any bug reports would be appreciated. Enjoy!

Download