2025/07/15 Update

Added PEPS AI.
Updated module name.
Set all henchmen to have a random race &/or class based name using a custom version of Markshire's Nomeclature scripts, as well as appearance.
Set Constructs, Undead, Outsiders & Elementals to not require food or drink.
Full compile.
This commit is contained in:
Jaysyn904
2025-07-15 22:19:46 -04:00
parent 239a2cd849
commit d77404f157
502 changed files with 147824 additions and 2042 deletions

View File

@@ -12,16 +12,42 @@ Henchman-specific OnSpawn handler for XP1. Based on NW_CH_AC9 by Bioware.
#include "x0_i0_anims"
#include "x0_inc_henai"
#include "x2_inc_switches"
#include "ms_name_inc"
#include "mmd_inc_random"
void main()
{
string sTag = GetTag(OBJECT_SELF);
object oReset = GetWaypointByTag(sTag);
object oRespawn = GetObjectByTag("NW_DEATH_TEMPLE");
location lRespawn = GetLocation(oRespawn);
location lReset = GetLocation(oReset);
//SetLocalInt(OBJECT_SELF,"X2_L_SPAWN_USE_AMBIENT",1);
object oNPC = OBJECT_SELF;
string sTag = GetTag(oNPC);
object oReset = GetWaypointByTag(sTag);
object oRespawn = GetObjectByTag("NW_DEATH_TEMPLE");
location lRespawn = GetLocation(oRespawn);
location lReset = GetLocation(oReset);
//SetLocalInt(oNPC,"X2_L_SPAWN_USE_AMBIENT",1);
//:: Don't want all the Henchmen to have a title.
if (d2(1) == 2)
{
DeleteLocalInt(oNPC, "RND_BARD");
DeleteLocalInt(oNPC, "RND_BARBARIAN");
DeleteLocalInt(oNPC, "RND_CLERIC");
DeleteLocalInt(oNPC, "RND_DRUID");
DeleteLocalInt(oNPC, "RND_FIGHTER");
DeleteLocalInt(oNPC, "RND_MAGE");
DeleteLocalInt(oNPC, "RND_MONK");
DeleteLocalInt(oNPC, "RND_PALADIN");
DeleteLocalInt(oNPC, "RND_RANGER");
DeleteLocalInt(oNPC, "RND_ROGUE");
}
ms_Nomenclature(oNPC);
DelayCommand(0.0f, rnd_skin(oNPC));
DelayCommand(0.0f, rnd_head(oNPC));
DelayCommand(0.0f, rnd_pheno(oNPC));
DelayCommand(0.0f, rnd_tattoo(oNPC));
DelayCommand(0.0f, rnd_height(oNPC));
//Sets up the special henchmen listening patterns
SetAssociateListenPatterns();
@@ -40,25 +66,26 @@ location lReset = GetLocation(oReset);
//Use melee weapons by default
SetAssociateState(NW_ASC_USE_RANGED_WEAPON, FALSE);
// Set starting location
//SetAssociateStartLocation();
// Set respawn location
// SetRespawnLocationSpecific(OBJECT_SELF, lRespawn);
// For some general behavior while we don't have a master,
// let's do some immobile animations
//SetSpawnInCondition(NW_FLAG_AMBIENT_ANIMATIONS);
SetSpawnInCondition(NW_FLAG_IMMOBILE_AMBIENT_ANIMATIONS);
//JumpToLocation(lReset);
int iRoll = Random(60)+1;
string sTag2 = "henchwp";
object oWP = GetObjectByTag(sTag2+IntToString(iRoll));
//ExecuteScript("nw_c2_default9",OBJECT_SELF);
//ActionForceMoveToObject(oWP,FALSE,3.0f);
JumpToObject(oWP);
//DelayCommand(6.0f,ActionRandomWalk());
if (GetIsHired(OBJECT_SELF)!=TRUE) SetAnimationCondition(NW_ANIM_FLAG_IS_ACTIVE);
}
int iRoll = Random(60)+1;
string sTag2 = "henchwp";
object oWP = GetObjectByTag(sTag2+IntToString(iRoll));
//ExecuteScript("nw_c2_default9",OBJECT_SELF);
//ActionForceMoveToObject(oWP,FALSE,3.0f);
JumpToObject(oWP);
// Set starting location
//SetAssociateStartLocation();
// Set respawn location
//SetRespawnLocationSpecific(oNPC, lRespawn);
//DelayCommand(6.0f,ActionRandomWalk());
if (GetIsHired(oNPC)!=TRUE) SetAnimationCondition(NW_ANIM_FLAG_IS_ACTIVE);
}