Been trying to make a trigger so that my constructs will not go hostile until the players enter a specific trigger area
So far my attempts have either messed with the whole faction making creatures hostile in other parts of the server
or nothing at all happens
Now to be fair I have mostly tested with NPCs
Current attempt is
#include "x0_i0_partywide"
#include "nw_i0_generic"
void main()
{
object oTarget;
// Get the creature who triggered this event.
object oPC = GetEnteringObject();
// Only fire for (real) PCs.
if ( !GetIsPC(oPC) || GetIsDMPossessed(oPC) )
return;
// Attack the PC.
ChangeToStandardFaction(oTarget, STANDARD_FACTION_HOSTILE);
AdjustReputation(oPC, oTarget, -100);
//AdjustReputation(oPC, GetNearestObjectByTag("009_cr_q24_golem"), -100);
SetIsTemporaryEnemy(oPC, GetNearestObjectByTag("009_cr_q24_golem"));
AssignCommand(GetNearestObjectByTag("009_cr_q24_golem"), DetermineCombatRound(oPC));
// Make "009_cr_q24_golem" dislike the PC's party more.
oTarget = GetObjectByTag("009_cr_q24_golem");
AdjustReputationWithFaction(oPC, oTarget, -100);
}
My Construct has a unique faction tag that should not mess with factions elsewhere





Volver arriba






