generated from Jaysyn/ModuleTemplate
Initial commit
Initial commit
This commit is contained in:
38
_module/nss/oai_default8.nss
Normal file
38
_module/nss/oai_default8.nss
Normal file
@@ -0,0 +1,38 @@
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Olander's AI
|
||||
// nw_c2_default8
|
||||
// by Don Anderson
|
||||
// dandersonru@msn.com
|
||||
//
|
||||
// OnDisturbed
|
||||
// Original Script by Bioware
|
||||
//
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "oai_inc_ai"
|
||||
|
||||
void main()
|
||||
{
|
||||
object oTarget = GetLastDisturbed();
|
||||
|
||||
// If we've been disturbed and are not already fighting,
|
||||
// attack our disturber.
|
||||
if (GetIsObjectValid(oTarget) && !GetIsFighting(OBJECT_SELF))
|
||||
{
|
||||
if(OAI_GetIsAlly(oTarget))
|
||||
{
|
||||
ClearAllActions(TRUE);
|
||||
OAI_DetermineCombatRound();
|
||||
}
|
||||
|
||||
OAI_DetermineCombatRound(oTarget);
|
||||
}
|
||||
|
||||
// Send the disturbed flag if appropriate.
|
||||
if(GetSpawnInCondition(NW_FLAG_DISTURBED_EVENT))
|
||||
{
|
||||
SignalEvent(OBJECT_SELF, EventUserDefined(EVENT_DISTURBED));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user