The faction info of a Creature/Player/GameObject.
More...
|
void | AdjustReputation (NwCreature creature, int adjustment) |
| Adjusts how this faction feels about the specified creature. More...
|
|
bool | Equals (NwFaction? other) |
|
override bool | Equals (object? obj) |
|
int | GetAverageReputation (NwGameObject target) |
| Gets an integer between 0 and 100 (inclusive) that represents how this faction feels about the specified target.
-> 0-10 means this faction is hostile to the target
-> 11-89 means this faction is neutral to the target
-> 90-100 means this faction is friendly to the target.
More...
|
|
NwCreature | GetBestACMember (NwCreature? referenceCreature=null, bool visible=false) |
| Gets the member with the highest AC in this faction. More...
|
|
override int | GetHashCode () |
|
NwCreature | GetLeastDamagedMember (NwCreature? referenceCreature=null, bool visible=false) |
| Gets the least damaged member in this faction that is visible from the specified object. More...
|
|
List< NwCreature > | GetMembers () |
| Gets all creatures that are members of this faction.
More...
|
|
NwCreature | GetMostDamagedMember (NwCreature? referenceCreature=null, bool visible=false) |
| Gets the most damaged member in this faction that is visible from the specified object. More...
|
|
int | GetReputation (NwGameObject target) |
| Gets an integer between 0 and 100 (inclusive) that represents how this faction feels about the specified target.
-> 0-10 means this faction is hostile to the target
-> 11-89 means this faction is neutral to the target
-> 90-100 means this faction is friendly to the target. More...
|
|
NwCreature | GetStrongestMember (NwCreature? referenceCreature=null, bool visible=false) |
| Gets the strongest member in this faction that is visible from the specified object. More...
|
|
NwCreature | GetWeakestMember (NwCreature? referenceCreature=null, bool visible=false) |
| Gets the weakest member in this faction that is visible from the specified object. More...
|
|
NwCreature | GetWorstACMember (NwCreature? referenceCreature=null, bool visible=false) |
| Gets the member with the lowest AC in this faction that is visible from the specified object. More...
|
|
void | SetReputation (NwGameObject target, int newReputation) |
| Sets how this faction feels about the specified creature.
-> 0-10 means this faction is hostile to the target.
-> 11-89 means this faction is neutral to the target.
-> 90-100 means this faction is friendly to the target. More...
|
|
The faction info of a Creature/Player/GameObject.
◆ AdjustReputation()
void Anvil.API.NwFaction.AdjustReputation |
( |
NwCreature |
creature, |
|
|
int |
adjustment |
|
) |
| |
|
inline |
Adjusts how this faction feels about the specified creature.
- Parameters
-
creature | The target creature for the reputation change. |
adjustment | The adjustment in reputation to make. |
◆ FromFactionId()
static ? NwFaction Anvil.API.NwFaction.FromFactionId |
( |
int |
factionId | ) |
|
|
inlinestatic |
Resolves a NwFaction from a faction id.
- Parameters
-
factionId | The id of the faction to resolve. |
- Returns
- The associated NwFaction instance. Null if the faction id is invalid.
◆ FromStandardFaction()
static ? NwFaction Anvil.API.NwFaction.FromStandardFaction |
( |
StandardFaction |
factionType | ) |
|
|
inlinestatic |
Resolves a NwFaction from a StandardFaction.
- Parameters
-
factionType | The faction type to resolve. |
- Returns
- The associated NwFaction instance. Null if the faction type is invalid.
◆ GetAverageReputation()
int Anvil.API.NwFaction.GetAverageReputation |
( |
NwGameObject |
target | ) |
|
|
inline |
Gets an integer between 0 and 100 (inclusive) that represents how this faction feels about the specified target.
-> 0-10 means this faction is hostile to the target
-> 11-89 means this faction is neutral to the target
-> 90-100 means this faction is friendly to the target.
- Parameters
-
target | The target object to check. |
◆ GetBestACMember()
NwCreature Anvil.API.NwFaction.GetBestACMember |
( |
NwCreature? |
referenceCreature = null , |
|
|
bool |
visible = false |
|
) |
| |
|
inline |
Gets the member with the highest AC in this faction.
- Parameters
-
referenceCreature | The reference creature. Bonuses and penalties against the reference creature will be considered when finding the best AC member. |
visible | Highly recommended to set to "true" on large NPC factions. Includes only creatures visible to referenceCreature. |
◆ GetLeastDamagedMember()
NwCreature Anvil.API.NwFaction.GetLeastDamagedMember |
( |
NwCreature? |
referenceCreature = null , |
|
|
bool |
visible = false |
|
) |
| |
|
inline |
Gets the least damaged member in this faction that is visible from the specified object.
- Parameters
-
referenceCreature | The reference creature, used to determine visibility. |
visible | Highly recommended to set to "true" on large NPC factions. Includes only creatures visible to referenceCreature. |
◆ GetMembers()
List<NwCreature> Anvil.API.NwFaction.GetMembers |
( |
| ) |
|
|
inline |
Gets all creatures that are members of this faction.
- Note
- This can be a very costly operation when used on large NPC factions.
- Returns
- All creatures in this faction.
◆ GetMostDamagedMember()
NwCreature Anvil.API.NwFaction.GetMostDamagedMember |
( |
NwCreature? |
referenceCreature = null , |
|
|
bool |
visible = false |
|
) |
| |
|
inline |
Gets the most damaged member in this faction that is visible from the specified object.
- Parameters
-
referenceCreature | The reference creature, used to determine visibility. |
visible | Highly recommended to set to "true" on large NPC factions. Includes only creatures visible to referenceCreature. |
◆ GetReputation()
int Anvil.API.NwFaction.GetReputation |
( |
NwGameObject |
target | ) |
|
|
inline |
Gets an integer between 0 and 100 (inclusive) that represents how this faction feels about the specified target.
-> 0-10 means this faction is hostile to the target
-> 11-89 means this faction is neutral to the target
-> 90-100 means this faction is friendly to the target.
- Parameters
-
- Returns
- 0-100 (inclusive) based on the standing of the target within this standard faction.
◆ GetStrongestMember()
NwCreature Anvil.API.NwFaction.GetStrongestMember |
( |
NwCreature? |
referenceCreature = null , |
|
|
bool |
visible = false |
|
) |
| |
|
inline |
Gets the strongest member in this faction that is visible from the specified object.
- Parameters
-
referenceCreature | The reference creature. Bonuses and penalties against the reference creature will be considered when finding the strongest member. |
visible | Highly recommended to set to "true" on large NPC factions. Includes only creatures visible to referenceCreature. |
◆ GetWeakestMember()
NwCreature Anvil.API.NwFaction.GetWeakestMember |
( |
NwCreature? |
referenceCreature = null , |
|
|
bool |
visible = false |
|
) |
| |
|
inline |
Gets the weakest member in this faction that is visible from the specified object.
- Parameters
-
referenceCreature | The reference creature. Bonuses and penalties against the reference creature will be considered when finding the weakest member. |
visible | Highly recommended to set to "true" on large NPC factions. Includes only creatures visible to referenceCreature. |
◆ GetWorstACMember()
NwCreature Anvil.API.NwFaction.GetWorstACMember |
( |
NwCreature? |
referenceCreature = null , |
|
|
bool |
visible = false |
|
) |
| |
|
inline |
Gets the member with the lowest AC in this faction that is visible from the specified object.
- Parameters
-
referenceCreature | The reference creature. Bonuses and penalties against the reference creature will be considered when finding the worst AC member. |
visible | Highly recommended to set to "true" on large NPC factions. Includes only creatures visible to referenceCreature. |
◆ SetReputation()
void Anvil.API.NwFaction.SetReputation |
( |
NwGameObject |
target, |
|
|
int |
newReputation |
|
) |
| |
|
inline |
Sets how this faction feels about the specified creature.
-> 0-10 means this faction is hostile to the target.
-> 11-89 means this faction is neutral to the target.
-> 90-100 means this faction is friendly to the target.
- Parameters
-
target | The target object. |
newReputation | A value between 0-100 (inclusive). |
◆ AverageGoodEvilAlignment
int Anvil.API.NwFaction.AverageGoodEvilAlignment |
|
get |
Gets the average Good/Evil alignment value of members in this faction.
- Note
- This can be a costly operation when used on large NPC factions.
◆ AverageLawChaosAlignment
int Anvil.API.NwFaction.AverageLawChaosAlignment |
|
get |
Gets the average Law/Chaos alignment value of members in this faction.
- Note
- This can be a costly operation when used on large NPC factions.
◆ AverageLevel
int Anvil.API.NwFaction.AverageLevel |
|
get |
Gets the average level of members in this faction.
- Note
- This can be a costly operation when used on large NPC factions.
◆ AverageXP
int Anvil.API.NwFaction.AverageXP |
|
get |
Gets the average amount of XP of members in this faction.
- Note
- This can be a costly operation when used on large NPC factions.
◆ Factions
IReadOnlyList<NwFaction> Anvil.API.NwFaction.Factions |
|
staticget |
Gets a list of all active factions.
◆ Gold
int Anvil.API.NwFaction.Gold |
|
get |
Gets the total amount of gold held by all members of this party.
- Note
- This can be a costly operation when used on large NPC factions.
◆ Id
int Anvil.API.NwFaction.Id |
|
get |
Gets the id of this faction.
◆ Leader
Gets the leader of this player faction (party).
◆ MostFrequentClass
NwClass Anvil.API.NwFaction.MostFrequentClass |
|
get |
Gets the most common type of class among the members of this faction/party.
- Note
- This can be a costly operation when used on large NPC factions.
◆ StandardFactionType
StandardFaction Anvil.API.NwFaction.StandardFactionType |
|
get |
Gets the StandardFaction type of this faction.
If this is a player or custom faction, returns an out-of-range value.
The documentation for this class was generated from the following file:
- NWN.Anvil/src/main/API/Ruleset/NwFaction.cs