Jump to content

Problems determining initial NPC hostility


generalmx

Recommended Posts

I'm working on a mod that requires determining whether the NPC you just killed was initially hostile to you or not. Here's what I tried so far:

 

- GetFactionRelation between player and Raiders, Creatures, some Freeside residents, etc. usually give "0", or Neutral, which is not helpful.

 

- Using NVSE I iterate over all GetActiveFactions for the killed, then check GetFactionReaction between each faction and "playerfaction" which also seems to always be "0" (Neutral) for Raiders, Creatures, and some townspeople, which again isn't helpful.

 

- GetPCEnemyOfFaction returns that the PC is not an enemy of the Raiders or Creature factions.

 

- Raiders have an initial Aggression AV of 2 which allows them to attack neutrals, however most creatures I've checked have an aggression AV of 1 which means they shouldn't attack neutrals, but they do. Just in case they have bad brains I also checked GetAV BrainCondition which if 0 can mean they ignore factions, but Mole Rats and such do apparently start with quite healthy brains of 100.

 

- Initially non-hostile NPCs, when Frenzied, will return "3" for both GetAV "Aggression" and GetBaseAV "Aggression".

 

- I also can't assume that all Creatures are hostile because not all Creatures ARE hostile.

 

- I even checked the Crime functions which again return that the player is not considered an enemy.

 

So I'm at a loss in figuring out if there is a way to determine initial hostility. Because the aggression value can change in combat I can't rely on it, but it seems like it may be the only deciding factor for Raiders and Fiends and such.

Edited by generalmx
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...