Initial module commit

Initial module commit.
This commit is contained in:
Jaysyn904
2021-08-29 23:34:48 -04:00
parent a7b44c3e1c
commit 0f13e6c538
4092 changed files with 8658543 additions and 0 deletions

View File

@@ -0,0 +1,33 @@
//69_hench_switch
// Henchman is not in soley ranged attack mode
// Created by: 69MEH69 Oct2004
#include "69_INC_HENAI"
void main()
{
object oPC = GetPCSpeaker();
SetCombatCondition(X0_COMBAT_FLAG_RANGED, FALSE);
SetLocalInt(OBJECT_SELF, "COMBAT_FLAG_SWITCH", TRUE);
ActionSpeakString("Very well.");
int nClass = GetClassByPosition(1);
switch(nClass)
{
case CLASS_TYPE_BARBARIAN:
case CLASS_TYPE_FIGHTER:
case CLASS_TYPE_PALADIN:
if(HasMeleeWeapon69(OBJECT_SELF))
{
SetAssociateState(NW_ASC_USE_RANGED_WEAPON, FALSE);
bkEquipMelee(oPC);
}
break;
default:
if(HasRangedWeapon69(OBJECT_SELF))
{
SetAssociateState(NW_ASC_USE_RANGED_WEAPON, TRUE);
bkEquipRanged(oPC);
}
break;
}
}