mirror of
https://bitbucket.org/seefoe/dsrc.git
synced 2026-07-31 01:15:55 -04:00
26 lines
521 B
Plaintext
26 lines
521 B
Plaintext
/***** INCLUDES ********************************************************/
|
|
|
|
include library.ai_lib;
|
|
|
|
/***** TRIGGERS ********************************************************/
|
|
|
|
trigger OnAttach()
|
|
{
|
|
messageTo (self, "msgCheckCombat", null, 30, false);
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
/***** MESSAGEHANDLERS *************************************************/
|
|
|
|
messageHandler msgCheckCombat()
|
|
{
|
|
if(!isIncapacitated(self) || !isDead(self) || !ai_lib.isInCombat(self))
|
|
{
|
|
destroyObject(self);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|