DB/FactionTemplate: Difference between revisions
Jump to navigation
Jump to search
m (add full and correct info for 6.0.1.18179) |
(Added group descriptors.) |
||
(18 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
==Structure== | ==Structure== | ||
'''Column Field Type Notes''' | '''Column Field Type Notes''' | ||
1 ID Integer | 1 ID Integer | ||
2 iRefID_[[Faction.dbc|Faction]] Integer | 2 iRefID_[[Faction.dbc|Faction]] Integer | ||
3 | 3 [[FactionTemplate.dbc#Flags|Flags]] BitMask* | ||
4 [[FactionGroup.dbc| | 4 [[FactionGroup.dbc|FactionGroup]] BitMask LUA::GetFactionForRace shifts 1 by maskID in FactionGroup and & it with this column. | ||
5 | 5 FriendGroup BitMask* | ||
6 | 6 EnemyGroup BitMask* | ||
7 iRefID_[[Faction.dbc|Faction]] Integer | 7 iRefID_[[Faction.dbc|Faction]] Integer enemies 1 | ||
8 iRefID_[[Faction.dbc|Faction]] Integer | 8 iRefID_[[Faction.dbc|Faction]] Integer enemies 2 | ||
9 | 9 iRefID_[[Faction.dbc|Faction]] Integer enemies 3 | ||
10 | 10 iRefID_[[Faction.dbc|Faction]] Integer enemies 4 | ||
11 iRefID_[[Faction.dbc|Faction]] Integer | 11 iRefID_[[Faction.dbc|Faction]] Integer friend 1 | ||
12 iRefID_[[Faction.dbc|Faction]] Integer | 12 iRefID_[[Faction.dbc|Faction]] Integer friend 2 | ||
13 iRefID_[[Faction.dbc|Faction]] Integer | 13 iRefID_[[Faction.dbc|Faction]] Integer friend 3 | ||
14 iRefID_[[Faction.dbc|Faction]] Integer | 14 iRefID_[[Faction.dbc|Faction]] Integer friend 4 | ||
uint32 ID; // 0 m_ID | uint32 ID; // 0 m_ID | ||
uint32 faction; // 1 m_faction | uint32 faction; // 1 m_faction | ||
Line 33: | Line 25: | ||
uint32 friendFaction[4]; // 10 m_friend[4] | uint32 friendFaction[4]; // 10 m_friend[4] | ||
==6.0.1.18179== | ==0.5.3.3368, 1.12.1.5875, 6.0.1.18179== | ||
struct FactionTemplateRec { | struct FactionTemplateRec { | ||
uint32_t m_ID; | |||
uint32_t m_faction; | |||
#if {{Template:Sandbox/VersionRange|min_expansionlevel=1}} | |||
uint32_t m_flags; | |||
#endif | |||
uint32_t m_factionGroup; // (m_factionGroup & 7) == 1 → neutral | |||
uint32_t m_friendGroup; | |||
uint32_t m_enemyGroup; | |||
uint32_t m_enemies[4]; | |||
uint32_t m_friend[4]; | |||
}; | }; | ||
[[Category:DBC]][[Category:DBC_WotLK]] | |||
==3.3.5.12340== | |||
Defines column 3(FactionGroup), 4(FriendGroup), and 5(EnemyGroup). | |||
{| class="wikitable sortable" | |||
|- | |||
! Flag !! Bitmask !! Description | |||
|- | |||
| 0 || 0x00 || 0 - None. | |||
|- | |||
| 1 || 0x01 || 1 - All players (and pets). | |||
|- | |||
| 2 || 0x02 || 2 - Alliance players (and their pets). | |||
|- | |||
| 4 || 0x04 || 3 - Horde players (and their pets). | |||
|- | |||
| 8 || 0x08 || 4 - Monster (Not a player nor a pet). | |||
|} | |||
===Flags=== | |||
{| style="background:#FCFCFC; color:black" | |||
|- | |||
! width="80" | Value | |||
! width="400" | Description | |||
|- | |||
| 0x0001 || Respond to call for help | |||
|- | |||
| 0x0002 || Broadcast to enemies (low priority) | |||
|- | |||
| 0x0004 || Broadcast to enemies (med priority) | |||
|- | |||
| 0x0008 || Broadcast to enemies (high priority) | |||
|- | |||
| 0x0010 || Search for enemies (low priority) | |||
|- | |||
| 0x0020 || Search for enemies (med priority) | |||
|- | |||
| 0x0040 || Search for enemies (high priority) | |||
|- | |||
| 0x0080 || Search for friends (low priority) | |||
|- | |||
| 0x0100 || Search for friends (med priority) | |||
|- | |||
| 0x0200 || Search for friends (high priority) | |||
|- | |||
| 0x0400 || Flee from call for help | |||
|- | |||
| 0x0800 || Assist players | |||
|- | |||
| 0x1000 || Attack PvP active players | |||
|- | |||
| 0x2000 || Hates all except friends | |||
|} | |||
[[Category:DBC]] | |||
[[Category:DBC_Alpha]] | |||
[[Category:DBC_Vanilla]] | |||
[[Category:DBC_WotLK]] | |||
[[Category:DBC_WoD]][[Category:6.0.1.18179]] |
Latest revision as of 08:16, 8 February 2022
Structure
Column Field Type Notes 1 ID Integer 2 iRefID_Faction Integer 3 Flags BitMask* 4 FactionGroup BitMask LUA::GetFactionForRace shifts 1 by maskID in FactionGroup and & it with this column. 5 FriendGroup BitMask* 6 EnemyGroup BitMask* 7 iRefID_Faction Integer enemies 1 8 iRefID_Faction Integer enemies 2 9 iRefID_Faction Integer enemies 3 10 iRefID_Faction Integer enemies 4 11 iRefID_Faction Integer friend 1 12 iRefID_Faction Integer friend 2 13 iRefID_Faction Integer friend 3 14 iRefID_Faction Integer friend 4
uint32 ID; // 0 m_ID uint32 faction; // 1 m_faction uint32 factionFlags; // 2 m_flags uint32 ourMask; // 3 m_factionGroup uint32 friendlyMask; // 4 m_friendGroup uint32 hostileMask; // 5 m_enemyGroup uint32 enemyFaction[4]; // 6 m_enemies[4] uint32 friendFaction[4]; // 10 m_friend[4]
0.5.3.3368, 1.12.1.5875, 6.0.1.18179
struct FactionTemplateRec { uint32_t m_ID; uint32_t m_faction; #if ≥ uint32_t m_flags; #endif uint32_t m_factionGroup; // (m_factionGroup & 7) == 1 → neutral uint32_t m_friendGroup; uint32_t m_enemyGroup; uint32_t m_enemies[4]; uint32_t m_friend[4]; };
3.3.5.12340
Defines column 3(FactionGroup), 4(FriendGroup), and 5(EnemyGroup).
Flag | Bitmask | Description |
---|---|---|
0 | 0x00 | 0 - None. |
1 | 0x01 | 1 - All players (and pets). |
2 | 0x02 | 2 - Alliance players (and their pets). |
4 | 0x04 | 3 - Horde players (and their pets). |
8 | 0x08 | 4 - Monster (Not a player nor a pet). |
Flags
Value | Description |
---|---|
0x0001 | Respond to call for help |
0x0002 | Broadcast to enemies (low priority) |
0x0004 | Broadcast to enemies (med priority) |
0x0008 | Broadcast to enemies (high priority) |
0x0010 | Search for enemies (low priority) |
0x0020 | Search for enemies (med priority) |
0x0040 | Search for enemies (high priority) |
0x0080 | Search for friends (low priority) |
0x0100 | Search for friends (med priority) |
0x0200 | Search for friends (high priority) |
0x0400 | Flee from call for help |
0x0800 | Assist players |
0x1000 | Attack PvP active players |
0x2000 | Hates all except friends |