PRC8/nwn/nwnprc/trunk/scripts/prc_hen_heart.nss
Jaysyn904 6ec137a24e Updated AMS marker feats
Updated AMS marker feats.  Removed arcane & divine marker feats.  Updated Dread Necromancer for epic progression. Updated weapon baseitem models.  Updated new weapons for crafting & npc equip.
 Updated prefix.  Updated release archive.
2024-02-11 14:01:05 -05:00

51 lines
1.2 KiB
Plaintext

//:://////////////////////////////////////////////////
//:: X0_CH_HEN_HEART
/*
OnHeartbeat event handler for henchmen/associates.
*/
//:://////////////////////////////////////////////////
//:: Copyright (c) 2002 Floodgate Entertainment
//:: Created By: Naomi Novik
//:: Created On: 01/05/2003
//:://////////////////////////////////////////////////
#include "prc_alterations"
#include "X0_INC_HENAI"
void main()
{ // SpawnScriptDebugger();
if (GetMaster()== OBJECT_INVALID) DestroyObject(OBJECT_SELF);
// If the henchman is in dying mode, make sure
// they are non commandable. Sometimes they seem to
// 'slip' out of this mode
int bDying = GetIsHenchmanDying();
if (bDying == TRUE)
{
int bCommandable = GetCommandable();
if (bCommandable == TRUE)
{
// lie down again
ActionPlayAnimation(ANIMATION_LOOPING_DEAD_FRONT,
1.0, 65.0);
SetCommandable(FALSE);
}
}
// If we're dying or busy, we return
// (without sending the user-defined event)
if(GetAssociateState(NW_ASC_IS_BUSY) ||
bDying)
return;
ExecuteScript("nw_ch_ac1", OBJECT_SELF);
}