TrinityCore
Loading...
Searching...
No Matches
FactionTemplateEntry Struct Reference

#include <DB2Structure.h>

Public Member Functions

bool IsFriendlyTo (FactionTemplateEntry const *entry) const
 
bool IsHostileTo (FactionTemplateEntry const *entry) const
 
bool IsHostileToPlayers () const
 
bool IsNeutralToAll () const
 
bool IsContestedGuardFaction () const
 

Public Attributes

uint32 ID
 
uint16 Faction
 
int32 Flags
 
uint8 FactionGroup
 
uint8 FriendGroup
 
uint8 EnemyGroup
 
std::array< uint16, MAX_FACTION_RELATIONS > Enemies
 
std::array< uint16, MAX_FACTION_RELATIONS > Friend
 

Detailed Description

Definition at line 1706 of file DB2Structure.h.

Member Function Documentation

◆ IsContestedGuardFaction()

bool FactionTemplateEntry::IsContestedGuardFaction ( ) const
inline

Definition at line 1758 of file DB2Structure.h.

References FACTION_TEMPLATE_FLAG_CONTESTED_GUARD, and Flags.

◆ IsFriendlyTo()

◆ IsHostileTo()

bool FactionTemplateEntry::IsHostileTo ( FactionTemplateEntry const *  entry) const
inline

◆ IsHostileToPlayers()

bool FactionTemplateEntry::IsHostileToPlayers ( ) const
inline

Definition at line 1750 of file DB2Structure.h.

References EnemyGroup, and FACTION_MASK_PLAYER.

Referenced by WorldObject::IsHostileToPlayers().

◆ IsNeutralToAll()

bool FactionTemplateEntry::IsNeutralToAll ( ) const
inline

Definition at line 1751 of file DB2Structure.h.

References Enemies, EnemyGroup, FriendGroup, and MAX_FACTION_RELATIONS.

Referenced by WorldObject::IsNeutralToAll().

Member Data Documentation

◆ Enemies

std::array<uint16, MAX_FACTION_RELATIONS> FactionTemplateEntry::Enemies

Definition at line 1714 of file DB2Structure.h.

Referenced by IsFriendlyTo(), IsHostileTo(), and IsNeutralToAll().

◆ EnemyGroup

uint8 FactionTemplateEntry::EnemyGroup

◆ Faction

◆ FactionGroup

◆ Flags

int32 FactionTemplateEntry::Flags

Definition at line 1710 of file DB2Structure.h.

Referenced by WorldObject::GetFactionReactionTo(), and IsContestedGuardFaction().

◆ Friend

std::array<uint16, MAX_FACTION_RELATIONS> FactionTemplateEntry::Friend

Definition at line 1715 of file DB2Structure.h.

Referenced by IsFriendlyTo(), and IsHostileTo().

◆ FriendGroup

uint8 FactionTemplateEntry::FriendGroup

◆ ID

uint32 FactionTemplateEntry::ID

Definition at line 1708 of file DB2Structure.h.


The documentation for this struct was generated from the following file: