TrinityCore
UnitDefines.h File Reference
#include "Define.h"
#include <string>
+ Include dependency graph for UnitDefines.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  DeclinedName
 

Macros

#define MIN_MELEE_REACH   2.0f
 
#define NOMINAL_MELEE_RANGE   5.0f
 
#define MELEE_RANGE   (NOMINAL_MELEE_RANGE - MIN_MELEE_REACH * 2)
 
#define BASE_MINDAMAGE   1.0f
 
#define BASE_MAXDAMAGE   2.0f
 
#define BASE_ATTACK_TIME   2000
 
#define MAX_EQUIPMENT_ITEMS   3
 
#define MAX_SHEATH_STATE   3
 
#define MAX_MOVE_TYPE   9
 
#define MAX_DECLINED_NAME_CASES   5
 

Enumerations

enum  UnitStandStateType : uint8 {
  UNIT_STAND_STATE_STAND = 0, UNIT_STAND_STATE_SIT = 1, UNIT_STAND_STATE_SIT_CHAIR = 2, UNIT_STAND_STATE_SLEEP = 3,
  UNIT_STAND_STATE_SIT_LOW_CHAIR = 4, UNIT_STAND_STATE_SIT_MEDIUM_CHAIR = 5, UNIT_STAND_STATE_SIT_HIGH_CHAIR = 6, UNIT_STAND_STATE_DEAD = 7,
  UNIT_STAND_STATE_KNEEL = 8, UNIT_STAND_STATE_SUBMERGED = 9
}
 
enum  UnitVisFlags : uint8 {
  UNIT_VIS_FLAGS_UNK1 = 0x01, UNIT_VIS_FLAGS_CREEP = 0x02, UNIT_VIS_FLAGS_UNTRACKABLE = 0x04, UNIT_VIS_FLAGS_UNK4 = 0x08,
  UNIT_VIS_FLAGS_UNK5 = 0x10, UNIT_VIS_FLAGS_ALL = 0xFF
}
 
enum  UnitBytes1_Flags : uint8 {
  UNIT_BYTE1_FLAG_NONE = 0x00, UNIT_BYTE1_FLAG_ALWAYS_STAND = 0x01, UNIT_BYTE1_FLAG_HOVER = 0x02, UNIT_BYTE1_FLAG_UNK_3 = 0x04,
  UNIT_BYTE1_FLAG_ALL = 0xFF
}
 
enum  SheathState : uint8 { SHEATH_STATE_UNARMED = 0, SHEATH_STATE_MELEE = 1, SHEATH_STATE_RANGED = 2 }
 
enum  UnitPVPStateFlags : uint8 {
  UNIT_BYTE2_FLAG_NONE = 0x00, UNIT_BYTE2_FLAG_PVP = 0x01, UNIT_BYTE2_FLAG_UNK1 = 0x02, UNIT_BYTE2_FLAG_FFA_PVP = 0x04,
  UNIT_BYTE2_FLAG_SANCTUARY = 0x08, UNIT_BYTE2_FLAG_UNK4 = 0x10, UNIT_BYTE2_FLAG_UNK5 = 0x20, UNIT_BYTE2_FLAG_UNK6 = 0x40,
  UNIT_BYTE2_FLAG_UNK7 = 0x80
}
 
enum  UnitPetFlag : uint8 { UNIT_PET_FLAG_NONE = 0x0, UNIT_PET_FLAG_CAN_BE_RENAMED = 0x01, UNIT_PET_FLAG_CAN_BE_ABANDONED = 0x02 }
 
enum  UnitMoveType {
  MOVE_WALK = 0, MOVE_RUN = 1, MOVE_RUN_BACK = 2, MOVE_SWIM = 3,
  MOVE_SWIM_BACK = 4, MOVE_TURN_RATE = 5, MOVE_FLIGHT = 6, MOVE_FLIGHT_BACK = 7,
  MOVE_PITCH_RATE = 8
}
 
enum  UnitFlags : uint32 {
  UNIT_FLAG_SERVER_CONTROLLED = 0x00000001, UNIT_FLAG_NON_ATTACKABLE = 0x00000002, UNIT_FLAG_REMOVE_CLIENT_CONTROL = 0x00000004, UNIT_FLAG_PLAYER_CONTROLLED = 0x00000008,
  UNIT_FLAG_RENAME = 0x00000010, UNIT_FLAG_PREPARATION = 0x00000020, UNIT_FLAG_UNK_6 = 0x00000040, UNIT_FLAG_NOT_ATTACKABLE_1 = 0x00000080,
  UNIT_FLAG_IMMUNE_TO_PC = 0x00000100, UNIT_FLAG_IMMUNE_TO_NPC = 0x00000200, UNIT_FLAG_LOOTING = 0x00000400, UNIT_FLAG_PET_IN_COMBAT = 0x00000800,
  UNIT_FLAG_PVP = 0x00001000, UNIT_FLAG_SILENCED = 0x00002000, UNIT_FLAG_CANNOT_SWIM = 0x00004000, UNIT_FLAG_UNK_15 = 0x00008000,
  UNIT_FLAG_NON_ATTACKABLE_2 = 0x00010000, UNIT_FLAG_PACIFIED = 0x00020000, UNIT_FLAG_STUNNED = 0x00040000, UNIT_FLAG_IN_COMBAT = 0x00080000,
  UNIT_FLAG_TAXI_FLIGHT = 0x00100000, UNIT_FLAG_DISARMED = 0x00200000, UNIT_FLAG_CONFUSED = 0x00400000, UNIT_FLAG_FLEEING = 0x00800000,
  UNIT_FLAG_POSSESSED = 0x01000000, UNIT_FLAG_NOT_SELECTABLE = 0x02000000, UNIT_FLAG_SKINNABLE = 0x04000000, UNIT_FLAG_MOUNT = 0x08000000,
  UNIT_FLAG_UNK_28 = 0x10000000, UNIT_FLAG_UNK_29 = 0x20000000, UNIT_FLAG_SHEATHE = 0x40000000, UNIT_FLAG_UNK_31 = 0x80000000,
  MAX_UNIT_FLAGS = 32
}
 
enum  UnitFlags2 : uint32 {
  UNIT_FLAG2_FEIGN_DEATH = 0x00000001, UNIT_FLAG2_UNK1 = 0x00000002, UNIT_FLAG2_IGNORE_REPUTATION = 0x00000004, UNIT_FLAG2_COMPREHEND_LANG = 0x00000008,
  UNIT_FLAG2_MIRROR_IMAGE = 0x00000010, UNIT_FLAG2_INSTANTLY_APPEAR_MODEL = 0x00000020, UNIT_FLAG2_FORCE_MOVEMENT = 0x00000040, UNIT_FLAG2_DISARM_OFFHAND = 0x00000080,
  UNIT_FLAG2_DISABLE_PRED_STATS = 0x00000100, UNIT_FLAG2_ALLOW_CHANGING_TALENTS = 0x00000200, UNIT_FLAG2_DISARM_RANGED = 0x00000400, UNIT_FLAG2_REGENERATE_POWER = 0x00000800,
  UNIT_FLAG2_RESTRICT_PARTY_INTERACTION = 0x00001000, UNIT_FLAG2_PREVENT_SPELL_CLICK = 0x00002000, UNIT_FLAG2_ALLOW_ENEMY_INTERACT = 0x00004000, UNIT_FLAG2_DISABLE_TURN = 0x00008000,
  UNIT_FLAG2_UNK2 = 0x00010000, UNIT_FLAG2_PLAY_DEATH_ANIM = 0x00020000, UNIT_FLAG2_ALLOW_CHEAT_SPELLS = 0x00040000, UNIT_FLAG2_NO_ACTIONS = 0x00800000,
  MAX_UNIT_FLAGS_2 = 19
}
 
enum  UnitFlags3 : uint32 { UNIT_FLAG3_UNK1 = 0x00000001, MAX_UNIT_FLAGS_3 = 1 }
 
enum  NPCFlags : uint32 {
  UNIT_NPC_FLAG_NONE = 0x00000000, UNIT_NPC_FLAG_GOSSIP = 0x00000001, UNIT_NPC_FLAG_QUESTGIVER = 0x00000002, UNIT_NPC_FLAG_UNK1 = 0x00000004,
  UNIT_NPC_FLAG_UNK2 = 0x00000008, UNIT_NPC_FLAG_TRAINER = 0x00000010, UNIT_NPC_FLAG_TRAINER_CLASS = 0x00000020, UNIT_NPC_FLAG_TRAINER_PROFESSION = 0x00000040,
  UNIT_NPC_FLAG_VENDOR = 0x00000080, UNIT_NPC_FLAG_VENDOR_AMMO = 0x00000100, UNIT_NPC_FLAG_VENDOR_FOOD = 0x00000200, UNIT_NPC_FLAG_VENDOR_POISON = 0x00000400,
  UNIT_NPC_FLAG_VENDOR_REAGENT = 0x00000800, UNIT_NPC_FLAG_REPAIR = 0x00001000, UNIT_NPC_FLAG_FLIGHTMASTER = 0x00002000, UNIT_NPC_FLAG_SPIRITHEALER = 0x00004000,
  UNIT_NPC_FLAG_SPIRITGUIDE = 0x00008000, UNIT_NPC_FLAG_INNKEEPER = 0x00010000, UNIT_NPC_FLAG_BANKER = 0x00020000, UNIT_NPC_FLAG_PETITIONER = 0x00040000,
  UNIT_NPC_FLAG_TABARDDESIGNER = 0x00080000, UNIT_NPC_FLAG_BATTLEMASTER = 0x00100000, UNIT_NPC_FLAG_AUCTIONEER = 0x00200000, UNIT_NPC_FLAG_STABLEMASTER = 0x00400000,
  UNIT_NPC_FLAG_GUILD_BANKER = 0x00800000, UNIT_NPC_FLAG_SPELLCLICK = 0x01000000, UNIT_NPC_FLAG_PLAYER_VEHICLE = 0x02000000, UNIT_NPC_FLAG_MAILBOX = 0x04000000,
  UNIT_NPC_FLAG_ARTIFACT_POWER_RESPEC = 0x08000000, UNIT_NPC_FLAG_TRANSMOGRIFIER = 0x10000000, UNIT_NPC_FLAG_VAULTKEEPER = 0x20000000, UNIT_NPC_FLAG_WILD_BATTLE_PET = 0x40000000,
  UNIT_NPC_FLAG_BLACK_MARKET = 0x80000000
}
 Non Player Character flags. More...
 
enum  NPCFlags2 : uint32 {
  UNIT_NPC_FLAG_2_NONE = 0x000, UNIT_NPC_FLAG_2_ITEM_UPGRADE_MASTER = 0x001, UNIT_NPC_FLAG_2_GARRISON_ARCHITECT = 0x002, UNIT_NPC_FLAG_2_STEERING = 0x004,
  UNIT_NPC_FLAG_2_SHIPMENT_CRAFTER = 0x010, UNIT_NPC_FLAG_2_GARRISON_MISSION_NPC = 0x020, UNIT_NPC_FLAG_2_TRADESKILL_NPC = 0x040, UNIT_NPC_FLAG_2_BLACK_MARKET_VIEW = 0x080,
  UNIT_NPC_FLAG_2_CONTRIBUTION_COLLECTOR = 0x400
}
 
enum  MovementFlags : uint32 {
  MOVEMENTFLAG_NONE = 0x00000000, MOVEMENTFLAG_FORWARD = 0x00000001, MOVEMENTFLAG_BACKWARD = 0x00000002, MOVEMENTFLAG_STRAFE_LEFT = 0x00000004,
  MOVEMENTFLAG_STRAFE_RIGHT = 0x00000008, MOVEMENTFLAG_LEFT = 0x00000010, MOVEMENTFLAG_RIGHT = 0x00000020, MOVEMENTFLAG_PITCH_UP = 0x00000040,
  MOVEMENTFLAG_PITCH_DOWN = 0x00000080, MOVEMENTFLAG_WALKING = 0x00000100, MOVEMENTFLAG_DISABLE_GRAVITY = 0x00000200, MOVEMENTFLAG_ROOT = 0x00000400,
  MOVEMENTFLAG_FALLING = 0x00000800, MOVEMENTFLAG_FALLING_FAR = 0x00001000, MOVEMENTFLAG_PENDING_STOP = 0x00002000, MOVEMENTFLAG_PENDING_STRAFE_STOP = 0x00004000,
  MOVEMENTFLAG_PENDING_FORWARD = 0x00008000, MOVEMENTFLAG_PENDING_BACKWARD = 0x00010000, MOVEMENTFLAG_PENDING_STRAFE_LEFT = 0x00020000, MOVEMENTFLAG_PENDING_STRAFE_RIGHT = 0x00040000,
  MOVEMENTFLAG_PENDING_ROOT = 0x00080000, MOVEMENTFLAG_SWIMMING = 0x00100000, MOVEMENTFLAG_ASCENDING = 0x00200000, MOVEMENTFLAG_DESCENDING = 0x00400000,
  MOVEMENTFLAG_CAN_FLY = 0x00800000, MOVEMENTFLAG_FLYING = 0x01000000, MOVEMENTFLAG_SPLINE_ELEVATION = 0x02000000, MOVEMENTFLAG_WATERWALKING = 0x04000000,
  MOVEMENTFLAG_FALLING_SLOW = 0x08000000, MOVEMENTFLAG_HOVER = 0x10000000, MOVEMENTFLAG_DISABLE_COLLISION = 0x20000000, MOVEMENTFLAG_MASK_MOVING,
  MOVEMENTFLAG_MASK_TURNING, MOVEMENTFLAG_MASK_MOVING_FLY, MOVEMENTFLAG_MASK_CREATURE_ALLOWED, MOVEMENTFLAG_MASK_PLAYER_ONLY,
  MOVEMENTFLAG_MASK_HAS_PLAYER_STATUS_OPCODE
}
 
enum  MovementFlags2 : uint32 {
  MOVEMENTFLAG2_NONE = 0x00000000, MOVEMENTFLAG2_NO_STRAFE = 0x00000001, MOVEMENTFLAG2_NO_JUMPING = 0x00000002, MOVEMENTFLAG2_FULL_SPEED_TURNING = 0x00000004,
  MOVEMENTFLAG2_FULL_SPEED_PITCHING = 0x00000008, MOVEMENTFLAG2_ALWAYS_ALLOW_PITCHING = 0x00000010, MOVEMENTFLAG2_IS_VEHICLE_EXIT_VOLUNTARY = 0x00000020, MOVEMENTFLAG2_WATERWALKING_FULL_PITCH = 0x00000040,
  MOVEMENTFLAG2_VEHICLE_PASSENGER_IS_TRANSITION_ALLOWED = 0x00000080, MOVEMENTFLAG2_CAN_SWIM_TO_FLY_TRANS = 0x00000100, MOVEMENTFLAG2_UNK9 = 0x00000200, MOVEMENTFLAG2_CAN_TURN_WHILE_FALLING = 0x00000400,
  MOVEMENTFLAG2_IGNORE_MOVEMENT_FORCES = 0x00000800, MOVEMENTFLAG2_CAN_DOUBLE_JUMP = 0x00001000, MOVEMENTFLAG2_DOUBLE_JUMP = 0x00002000, MOVEMENTFLAG2_AWAITING_LOAD = 0x00010000,
  MOVEMENTFLAG2_INTERPOLATED_MOVEMENT = 0x00020000, MOVEMENTFLAG2_INTERPOLATED_TURNING = 0x00040000, MOVEMENTFLAG2_INTERPOLATED_PITCHING = 0x00080000
}
 
enum  HitInfo {
  HITINFO_NORMALSWING = 0x00000000, HITINFO_UNK1 = 0x00000001, HITINFO_AFFECTS_VICTIM = 0x00000002, HITINFO_OFFHAND = 0x00000004,
  HITINFO_UNK2 = 0x00000008, HITINFO_MISS = 0x00000010, HITINFO_FULL_ABSORB = 0x00000020, HITINFO_PARTIAL_ABSORB = 0x00000040,
  HITINFO_FULL_RESIST = 0x00000080, HITINFO_PARTIAL_RESIST = 0x00000100, HITINFO_CRITICALHIT = 0x00000200, HITINFO_UNK10 = 0x00000400,
  HITINFO_UNK11 = 0x00000800, HITINFO_UNK12 = 0x00001000, HITINFO_BLOCK = 0x00002000, HITINFO_UNK14 = 0x00004000,
  HITINFO_UNK15 = 0x00008000, HITINFO_GLANCING = 0x00010000, HITINFO_CRUSHING = 0x00020000, HITINFO_NO_ANIMATION = 0x00040000,
  HITINFO_UNK19 = 0x00080000, HITINFO_UNK20 = 0x00100000, HITINFO_SWINGNOHITSOUND = 0x00200000, HITINFO_UNK22 = 0x00400000,
  HITINFO_RAGE_GAIN = 0x00800000, HITINFO_FAKE_DAMAGE = 0x01000000
}
 
enum  ActiveStates {
  ACT_PASSIVE = 0x01, ACT_DISABLED = 0x81, ACT_ENABLED = 0xC1, ACT_COMMAND = 0x07,
  ACT_REACTION = 0x06, ACT_DECIDE = 0x00
}
 
enum  ReactStates { REACT_PASSIVE = 0, REACT_DEFENSIVE = 1, REACT_AGGRESSIVE = 2, REACT_ASSIST = 3 }
 
enum  CommandStates : uint8 {
  COMMAND_STAY = 0, COMMAND_FOLLOW = 1, COMMAND_ATTACK = 2, COMMAND_ABANDON = 3,
  COMMAND_MOVE_TO = 4
}
 

Functions

char const * DescribeReactState (ReactStates state)
 

Macro Definition Documentation

◆ BASE_ATTACK_TIME

#define BASE_ATTACK_TIME   2000

◆ BASE_MAXDAMAGE

#define BASE_MAXDAMAGE   2.0f

◆ BASE_MINDAMAGE

#define BASE_MINDAMAGE   1.0f

◆ MAX_DECLINED_NAME_CASES

#define MAX_DECLINED_NAME_CASES   5

◆ MAX_EQUIPMENT_ITEMS

#define MAX_EQUIPMENT_ITEMS   3

◆ MAX_MOVE_TYPE

#define MAX_MOVE_TYPE   9

◆ MAX_SHEATH_STATE

#define MAX_SHEATH_STATE   3

◆ MELEE_RANGE

#define MELEE_RANGE   (NOMINAL_MELEE_RANGE - MIN_MELEE_REACH * 2)

◆ MIN_MELEE_REACH

#define MIN_MELEE_REACH   2.0f

◆ NOMINAL_MELEE_RANGE

#define NOMINAL_MELEE_RANGE   5.0f

Enumeration Type Documentation

◆ ActiveStates

Enumerator
ACT_PASSIVE 
ACT_DISABLED 
ACT_ENABLED 
ACT_COMMAND 
ACT_REACTION 
ACT_DECIDE 
359 {
360  ACT_PASSIVE = 0x01, // 0x01 - passive
361  ACT_DISABLED = 0x81, // 0x80 - castable
362  ACT_ENABLED = 0xC1, // 0x40 | 0x80 - auto cast + castable
363  ACT_COMMAND = 0x07, // 0x01 | 0x02 | 0x04
364  ACT_REACTION = 0x06, // 0x02 | 0x04
365  ACT_DECIDE = 0x00 // custom
366 };
Definition: UnitDefines.h:362
Definition: UnitDefines.h:364
Definition: UnitDefines.h:361
Definition: UnitDefines.h:363
Definition: UnitDefines.h:360
Definition: UnitDefines.h:365

◆ CommandStates

Enumerator
COMMAND_STAY 
COMMAND_FOLLOW 
COMMAND_ATTACK 
COMMAND_ABANDON 
COMMAND_MOVE_TO 
388  : uint8
389 {
390  COMMAND_STAY = 0,
391  COMMAND_FOLLOW = 1,
392  COMMAND_ATTACK = 2,
393  COMMAND_ABANDON = 3,
394  COMMAND_MOVE_TO = 4
395 };
Definition: UnitDefines.h:390
Definition: UnitDefines.h:392
Definition: UnitDefines.h:391
Definition: UnitDefines.h:393
uint8_t uint8
Definition: Define.h:154
Definition: UnitDefines.h:394

◆ HitInfo

enum HitInfo
Enumerator
HITINFO_NORMALSWING 
HITINFO_UNK1 
HITINFO_AFFECTS_VICTIM 
HITINFO_OFFHAND 
HITINFO_UNK2 
HITINFO_MISS 
HITINFO_FULL_ABSORB 
HITINFO_PARTIAL_ABSORB 
HITINFO_FULL_RESIST 
HITINFO_PARTIAL_RESIST 
HITINFO_CRITICALHIT 
HITINFO_UNK10 
HITINFO_UNK11 
HITINFO_UNK12 
HITINFO_BLOCK 
HITINFO_UNK14 
HITINFO_UNK15 
HITINFO_GLANCING 
HITINFO_CRUSHING 
HITINFO_NO_ANIMATION 
HITINFO_UNK19 
HITINFO_UNK20 
HITINFO_SWINGNOHITSOUND 
HITINFO_UNK22 
HITINFO_RAGE_GAIN 
HITINFO_FAKE_DAMAGE 
322 {
323  HITINFO_NORMALSWING = 0x00000000,
324  HITINFO_UNK1 = 0x00000001, // req correct packet structure
325  HITINFO_AFFECTS_VICTIM = 0x00000002,
326  HITINFO_OFFHAND = 0x00000004,
327  HITINFO_UNK2 = 0x00000008,
328  HITINFO_MISS = 0x00000010,
329  HITINFO_FULL_ABSORB = 0x00000020,
330  HITINFO_PARTIAL_ABSORB = 0x00000040,
331  HITINFO_FULL_RESIST = 0x00000080,
332  HITINFO_PARTIAL_RESIST = 0x00000100,
333  HITINFO_CRITICALHIT = 0x00000200, // critical hit
334  HITINFO_UNK10 = 0x00000400,
335  HITINFO_UNK11 = 0x00000800,
336  HITINFO_UNK12 = 0x00001000,
337  HITINFO_BLOCK = 0x00002000, // blocked damage
338  HITINFO_UNK14 = 0x00004000, // set only if meleespellid is present// no world text when victim is hit for 0 dmg(HideWorldTextForNoDamage?)
339  HITINFO_UNK15 = 0x00008000, // player victim?// something related to blod sprut visual (BloodSpurtInBack?)
340  HITINFO_GLANCING = 0x00010000,
341  HITINFO_CRUSHING = 0x00020000,
342  HITINFO_NO_ANIMATION = 0x00040000,
343  HITINFO_UNK19 = 0x00080000,
344  HITINFO_UNK20 = 0x00100000,
345  HITINFO_SWINGNOHITSOUND = 0x00200000, // unused?
346  HITINFO_UNK22 = 0x00400000,
347  HITINFO_RAGE_GAIN = 0x00800000,
348  HITINFO_FAKE_DAMAGE = 0x01000000 // enables damage animation even if no damage done, set only if no damage
349 };
Definition: UnitDefines.h:337
Definition: UnitDefines.h:333
Definition: UnitDefines.h:345
Definition: UnitDefines.h:334
Definition: UnitDefines.h:332
Definition: UnitDefines.h:348
Definition: UnitDefines.h:347
Definition: UnitDefines.h:330
Definition: UnitDefines.h:341
Definition: UnitDefines.h:323
Definition: UnitDefines.h:324
Definition: UnitDefines.h:325
Definition: UnitDefines.h:339
Definition: UnitDefines.h:340
Definition: UnitDefines.h:346
Definition: UnitDefines.h:342
Definition: UnitDefines.h:336
Definition: UnitDefines.h:326
Definition: UnitDefines.h:329
Definition: UnitDefines.h:335
Definition: UnitDefines.h:344
Definition: UnitDefines.h:331
Definition: UnitDefines.h:328
Definition: UnitDefines.h:338
Definition: UnitDefines.h:327
Definition: UnitDefines.h:343

◆ MovementFlags

Enumerator
MOVEMENTFLAG_NONE 
MOVEMENTFLAG_FORWARD 
MOVEMENTFLAG_BACKWARD 
MOVEMENTFLAG_STRAFE_LEFT 
MOVEMENTFLAG_STRAFE_RIGHT 
MOVEMENTFLAG_LEFT 
MOVEMENTFLAG_RIGHT 
MOVEMENTFLAG_PITCH_UP 
MOVEMENTFLAG_PITCH_DOWN 
MOVEMENTFLAG_WALKING 
MOVEMENTFLAG_DISABLE_GRAVITY 
MOVEMENTFLAG_ROOT 
MOVEMENTFLAG_FALLING 
MOVEMENTFLAG_FALLING_FAR 
MOVEMENTFLAG_PENDING_STOP 
MOVEMENTFLAG_PENDING_STRAFE_STOP 
MOVEMENTFLAG_PENDING_FORWARD 
MOVEMENTFLAG_PENDING_BACKWARD 
MOVEMENTFLAG_PENDING_STRAFE_LEFT 
MOVEMENTFLAG_PENDING_STRAFE_RIGHT 
MOVEMENTFLAG_PENDING_ROOT 
MOVEMENTFLAG_SWIMMING 
MOVEMENTFLAG_ASCENDING 
MOVEMENTFLAG_DESCENDING 
MOVEMENTFLAG_CAN_FLY 
MOVEMENTFLAG_FLYING 
MOVEMENTFLAG_SPLINE_ELEVATION 
MOVEMENTFLAG_WATERWALKING 
MOVEMENTFLAG_FALLING_SLOW 
MOVEMENTFLAG_HOVER 
MOVEMENTFLAG_DISABLE_COLLISION 
MOVEMENTFLAG_MASK_MOVING 
MOVEMENTFLAG_MASK_TURNING 
MOVEMENTFLAG_MASK_MOVING_FLY 
MOVEMENTFLAG_MASK_CREATURE_ALLOWED 
MOVEMENTFLAG_MASK_PLAYER_ONLY 
Todo:
if needed: add more flags to this masks that are exclusive to players
MOVEMENTFLAG_MASK_HAS_PLAYER_STATUS_OPCODE 

Movement flags that have change status opcodes associated for players.

238  : uint32
239 {
240  MOVEMENTFLAG_NONE = 0x00000000,
241  MOVEMENTFLAG_FORWARD = 0x00000001,
242  MOVEMENTFLAG_BACKWARD = 0x00000002,
243  MOVEMENTFLAG_STRAFE_LEFT = 0x00000004,
244  MOVEMENTFLAG_STRAFE_RIGHT = 0x00000008,
245  MOVEMENTFLAG_LEFT = 0x00000010,
246  MOVEMENTFLAG_RIGHT = 0x00000020,
247  MOVEMENTFLAG_PITCH_UP = 0x00000040,
248  MOVEMENTFLAG_PITCH_DOWN = 0x00000080,
249  MOVEMENTFLAG_WALKING = 0x00000100, // Walking
250  MOVEMENTFLAG_DISABLE_GRAVITY = 0x00000200, // Former MOVEMENTFLAG_LEVITATING. This is used when walking is not possible.
251  MOVEMENTFLAG_ROOT = 0x00000400, // Must not be set along with MOVEMENTFLAG_MASK_MOVING
252  MOVEMENTFLAG_FALLING = 0x00000800, // damage dealt on that type of falling
253  MOVEMENTFLAG_FALLING_FAR = 0x00001000,
254  MOVEMENTFLAG_PENDING_STOP = 0x00002000,
256  MOVEMENTFLAG_PENDING_FORWARD = 0x00008000,
257  MOVEMENTFLAG_PENDING_BACKWARD = 0x00010000,
260  MOVEMENTFLAG_PENDING_ROOT = 0x00080000,
261  MOVEMENTFLAG_SWIMMING = 0x00100000, // appears with fly flag also
262  MOVEMENTFLAG_ASCENDING = 0x00200000, // press "space" when flying
263  MOVEMENTFLAG_DESCENDING = 0x00400000,
264  MOVEMENTFLAG_CAN_FLY = 0x00800000, // Appears when unit can fly. For example, appears when a player sits on a mount.
265  MOVEMENTFLAG_FLYING = 0x01000000, // unit is actually flying. pretty sure this is only used for players. creatures use disable_gravity
266  MOVEMENTFLAG_SPLINE_ELEVATION = 0x02000000, // used for flight paths
267  MOVEMENTFLAG_WATERWALKING = 0x04000000, // prevent unit from falling through water
268  MOVEMENTFLAG_FALLING_SLOW = 0x08000000, // active rogue safe fall spell (passive)
269  MOVEMENTFLAG_HOVER = 0x10000000, // hover, cannot jump
270  MOVEMENTFLAG_DISABLE_COLLISION = 0x20000000,
271 
275 
278 
281 
282  // Movement flags allowed for creature in CreateObject - we need to keep all other enabled serverside
283  // to properly calculate all movement
287 
291 
295 };
Definition: UnitDefines.h:260
Definition: UnitDefines.h:254
Definition: UnitDefines.h:253
Definition: UnitDefines.h:263
Definition: UnitDefines.h:269
Definition: UnitDefines.h:251
Definition: UnitDefines.h:268
Definition: UnitDefines.h:289
Definition: UnitDefines.h:262
Definition: UnitDefines.h:247
Definition: UnitDefines.h:248
Definition: UnitDefines.h:259
Definition: UnitDefines.h:257
Definition: UnitDefines.h:244
Definition: UnitDefines.h:242
Definition: UnitDefines.h:241
Definition: UnitDefines.h:252
Definition: UnitDefines.h:261
Movement flags that have change status opcodes associated for players.
Definition: UnitDefines.h:293
Definition: UnitDefines.h:255
uint32_t uint32
Definition: Define.h:152
Definition: UnitDefines.h:276
Definition: UnitDefines.h:258
Definition: UnitDefines.h:249
Definition: UnitDefines.h:279
Definition: UnitDefines.h:266
Definition: UnitDefines.h:256
Definition: UnitDefines.h:267
Definition: UnitDefines.h:272
Definition: UnitDefines.h:240
Definition: UnitDefines.h:246
Definition: UnitDefines.h:245
Definition: UnitDefines.h:270
Definition: UnitDefines.h:250
Definition: UnitDefines.h:284
Definition: UnitDefines.h:264
Definition: UnitDefines.h:243
Definition: UnitDefines.h:265

◆ MovementFlags2

Enumerator
MOVEMENTFLAG2_NONE 
MOVEMENTFLAG2_NO_STRAFE 
MOVEMENTFLAG2_NO_JUMPING 
MOVEMENTFLAG2_FULL_SPEED_TURNING 
MOVEMENTFLAG2_FULL_SPEED_PITCHING 
MOVEMENTFLAG2_ALWAYS_ALLOW_PITCHING 
MOVEMENTFLAG2_IS_VEHICLE_EXIT_VOLUNTARY 
MOVEMENTFLAG2_WATERWALKING_FULL_PITCH 
MOVEMENTFLAG2_VEHICLE_PASSENGER_IS_TRANSITION_ALLOWED 
MOVEMENTFLAG2_CAN_SWIM_TO_FLY_TRANS 
MOVEMENTFLAG2_UNK9 
MOVEMENTFLAG2_CAN_TURN_WHILE_FALLING 
MOVEMENTFLAG2_IGNORE_MOVEMENT_FORCES 
MOVEMENTFLAG2_CAN_DOUBLE_JUMP 
MOVEMENTFLAG2_DOUBLE_JUMP 
MOVEMENTFLAG2_AWAITING_LOAD 
MOVEMENTFLAG2_INTERPOLATED_MOVEMENT 
MOVEMENTFLAG2_INTERPOLATED_TURNING 
MOVEMENTFLAG2_INTERPOLATED_PITCHING 
297  : uint32
298 {
299  MOVEMENTFLAG2_NONE = 0x00000000,
300  MOVEMENTFLAG2_NO_STRAFE = 0x00000001,
301  MOVEMENTFLAG2_NO_JUMPING = 0x00000002,
306  MOVEMENTFLAG2_WATERWALKING_FULL_PITCH = 0x00000040, // will always waterwalk, even if facing the camera directly down
309  MOVEMENTFLAG2_UNK9 = 0x00000200, // terrain normal calculation is disabled if this flag is not present, client automatically handles setting this flag
312  MOVEMENTFLAG2_CAN_DOUBLE_JUMP = 0x00001000,
313  MOVEMENTFLAG2_DOUBLE_JUMP = 0x00002000,
314  // these flags are not sent
315  MOVEMENTFLAG2_AWAITING_LOAD = 0x00010000,
319 };
Definition: UnitDefines.h:313
Definition: UnitDefines.h:302
Definition: UnitDefines.h:318
Definition: UnitDefines.h:304
Definition: UnitDefines.h:305
Definition: UnitDefines.h:315
Definition: UnitDefines.h:301
Definition: UnitDefines.h:303
Definition: UnitDefines.h:299
Definition: UnitDefines.h:316
Definition: UnitDefines.h:317
uint32_t uint32
Definition: Define.h:152
Definition: UnitDefines.h:310
Definition: UnitDefines.h:309
Definition: UnitDefines.h:312
Definition: UnitDefines.h:311
Definition: UnitDefines.h:306
Definition: UnitDefines.h:300
Definition: UnitDefines.h:308

◆ NPCFlags

enum NPCFlags : uint32

Non Player Character flags.

Enumerator
UNIT_NPC_FLAG_NONE 
UNIT_NPC_FLAG_GOSSIP 
UNIT_NPC_FLAG_QUESTGIVER 
UNIT_NPC_FLAG_UNK1 
UNIT_NPC_FLAG_UNK2 
UNIT_NPC_FLAG_TRAINER 
UNIT_NPC_FLAG_TRAINER_CLASS 
UNIT_NPC_FLAG_TRAINER_PROFESSION 
UNIT_NPC_FLAG_VENDOR 
UNIT_NPC_FLAG_VENDOR_AMMO 
UNIT_NPC_FLAG_VENDOR_FOOD 
UNIT_NPC_FLAG_VENDOR_POISON 
UNIT_NPC_FLAG_VENDOR_REAGENT 
UNIT_NPC_FLAG_REPAIR 
UNIT_NPC_FLAG_FLIGHTMASTER 
UNIT_NPC_FLAG_SPIRITHEALER 
UNIT_NPC_FLAG_SPIRITGUIDE 
UNIT_NPC_FLAG_INNKEEPER 
UNIT_NPC_FLAG_BANKER 
UNIT_NPC_FLAG_PETITIONER 
UNIT_NPC_FLAG_TABARDDESIGNER 
UNIT_NPC_FLAG_BATTLEMASTER 
UNIT_NPC_FLAG_AUCTIONEER 
UNIT_NPC_FLAG_STABLEMASTER 
UNIT_NPC_FLAG_GUILD_BANKER 
UNIT_NPC_FLAG_SPELLCLICK 
UNIT_NPC_FLAG_PLAYER_VEHICLE 
UNIT_NPC_FLAG_MAILBOX 
UNIT_NPC_FLAG_ARTIFACT_POWER_RESPEC 
UNIT_NPC_FLAG_TRANSMOGRIFIER 
UNIT_NPC_FLAG_VAULTKEEPER 
UNIT_NPC_FLAG_WILD_BATTLE_PET 
UNIT_NPC_FLAG_BLACK_MARKET 
188  : uint32
189 {
190  UNIT_NPC_FLAG_NONE = 0x00000000,
191  UNIT_NPC_FLAG_GOSSIP = 0x00000001, // 100%
192  UNIT_NPC_FLAG_QUESTGIVER = 0x00000002, // 100%
193  UNIT_NPC_FLAG_UNK1 = 0x00000004,
194  UNIT_NPC_FLAG_UNK2 = 0x00000008,
195  UNIT_NPC_FLAG_TRAINER = 0x00000010, // 100%
196  UNIT_NPC_FLAG_TRAINER_CLASS = 0x00000020, // 100%
197  UNIT_NPC_FLAG_TRAINER_PROFESSION = 0x00000040, // 100%
198  UNIT_NPC_FLAG_VENDOR = 0x00000080, // 100%
199  UNIT_NPC_FLAG_VENDOR_AMMO = 0x00000100, // 100%, general goods vendor
200  UNIT_NPC_FLAG_VENDOR_FOOD = 0x00000200, // 100%
201  UNIT_NPC_FLAG_VENDOR_POISON = 0x00000400, // guessed
202  UNIT_NPC_FLAG_VENDOR_REAGENT = 0x00000800, // 100%
203  UNIT_NPC_FLAG_REPAIR = 0x00001000, // 100%
204  UNIT_NPC_FLAG_FLIGHTMASTER = 0x00002000, // 100%
205  UNIT_NPC_FLAG_SPIRITHEALER = 0x00004000, // guessed
206  UNIT_NPC_FLAG_SPIRITGUIDE = 0x00008000, // guessed
207  UNIT_NPC_FLAG_INNKEEPER = 0x00010000, // 100%
208  UNIT_NPC_FLAG_BANKER = 0x00020000, // 100%
209  UNIT_NPC_FLAG_PETITIONER = 0x00040000, // 100% 0xC0000 = guild petitions, 0x40000 = arena team petitions
210  UNIT_NPC_FLAG_TABARDDESIGNER = 0x00080000, // 100%
211  UNIT_NPC_FLAG_BATTLEMASTER = 0x00100000, // 100%
212  UNIT_NPC_FLAG_AUCTIONEER = 0x00200000, // 100%
213  UNIT_NPC_FLAG_STABLEMASTER = 0x00400000, // 100%
214  UNIT_NPC_FLAG_GUILD_BANKER = 0x00800000, //
215  UNIT_NPC_FLAG_SPELLCLICK = 0x01000000, //
216  UNIT_NPC_FLAG_PLAYER_VEHICLE = 0x02000000, // players with mounts that have vehicle data should have it set
217  UNIT_NPC_FLAG_MAILBOX = 0x04000000, // mailbox
218  UNIT_NPC_FLAG_ARTIFACT_POWER_RESPEC = 0x08000000, // artifact powers reset
219  UNIT_NPC_FLAG_TRANSMOGRIFIER = 0x10000000, // transmogrification
220  UNIT_NPC_FLAG_VAULTKEEPER = 0x20000000, // void storage
221  UNIT_NPC_FLAG_WILD_BATTLE_PET = 0x40000000, // Pet that player can fight (Battle Pet)
222  UNIT_NPC_FLAG_BLACK_MARKET = 0x80000000 // black market
223 };
Definition: UnitDefines.h:207
Definition: UnitDefines.h:218
Definition: UnitDefines.h:196
Definition: UnitDefines.h:214
Definition: UnitDefines.h:205
Definition: UnitDefines.h:220
Definition: UnitDefines.h:210
Definition: UnitDefines.h:201
Definition: UnitDefines.h:193
Definition: UnitDefines.h:198
Definition: UnitDefines.h:221
Definition: UnitDefines.h:216
Definition: UnitDefines.h:213
Definition: UnitDefines.h:208
Definition: UnitDefines.h:219
Definition: UnitDefines.h:211
Definition: UnitDefines.h:197
Definition: UnitDefines.h:217
Definition: UnitDefines.h:199
uint32_t uint32
Definition: Define.h:152
Definition: UnitDefines.h:192
Definition: UnitDefines.h:209
Definition: UnitDefines.h:203
Definition: UnitDefines.h:194
Definition: UnitDefines.h:212
Definition: UnitDefines.h:222
Definition: UnitDefines.h:204
Definition: UnitDefines.h:206
Definition: UnitDefines.h:191
Definition: UnitDefines.h:215
Definition: UnitDefines.h:202
Definition: UnitDefines.h:195
Definition: UnitDefines.h:190
Definition: UnitDefines.h:200

◆ NPCFlags2

enum NPCFlags2 : uint32
Enumerator
UNIT_NPC_FLAG_2_NONE 
UNIT_NPC_FLAG_2_ITEM_UPGRADE_MASTER 
UNIT_NPC_FLAG_2_GARRISON_ARCHITECT 
UNIT_NPC_FLAG_2_STEERING 
UNIT_NPC_FLAG_2_SHIPMENT_CRAFTER 
UNIT_NPC_FLAG_2_GARRISON_MISSION_NPC 
UNIT_NPC_FLAG_2_TRADESKILL_NPC 
UNIT_NPC_FLAG_2_BLACK_MARKET_VIEW 
UNIT_NPC_FLAG_2_CONTRIBUTION_COLLECTOR 
225  : uint32
226 {
227  UNIT_NPC_FLAG_2_NONE = 0x000,
230  UNIT_NPC_FLAG_2_STEERING = 0x004,
236 };
Definition: UnitDefines.h:227
Definition: UnitDefines.h:231
Definition: UnitDefines.h:233
Definition: UnitDefines.h:230
uint32_t uint32
Definition: Define.h:152
Definition: UnitDefines.h:232
Definition: UnitDefines.h:228
Definition: UnitDefines.h:234
Definition: UnitDefines.h:235
Definition: UnitDefines.h:229

◆ ReactStates

Enumerator
REACT_PASSIVE 
REACT_DEFENSIVE 
REACT_AGGRESSIVE 
REACT_ASSIST 
369 {
370  REACT_PASSIVE = 0,
371  REACT_DEFENSIVE = 1,
372  REACT_AGGRESSIVE = 2,
373  REACT_ASSIST = 3
374 };
Definition: UnitDefines.h:371
Definition: UnitDefines.h:372
Definition: UnitDefines.h:370
Definition: UnitDefines.h:373

◆ SheathState

Enumerator
SHEATH_STATE_UNARMED 
SHEATH_STATE_MELEE 
SHEATH_STATE_RANGED 
70  : uint8
71 {
72  SHEATH_STATE_UNARMED = 0, // non prepared weapon
73  SHEATH_STATE_MELEE = 1, // prepared melee weapon
74  SHEATH_STATE_RANGED = 2 // prepared ranged weapon
75 };
Definition: UnitDefines.h:73
Definition: UnitDefines.h:72
Definition: UnitDefines.h:74
uint8_t uint8
Definition: Define.h:154

◆ UnitBytes1_Flags

Enumerator
UNIT_BYTE1_FLAG_NONE 
UNIT_BYTE1_FLAG_ALWAYS_STAND 
UNIT_BYTE1_FLAG_HOVER 
UNIT_BYTE1_FLAG_UNK_3 
UNIT_BYTE1_FLAG_ALL 
60  : uint8
61 {
62  UNIT_BYTE1_FLAG_NONE = 0x00,
64  UNIT_BYTE1_FLAG_HOVER = 0x02,
65  UNIT_BYTE1_FLAG_UNK_3 = 0x04,
66  UNIT_BYTE1_FLAG_ALL = 0xFF
67 };
Definition: UnitDefines.h:63
Definition: UnitDefines.h:66
Definition: UnitDefines.h:65
uint8_t uint8
Definition: Define.h:154
Definition: UnitDefines.h:64
Definition: UnitDefines.h:62

◆ UnitFlags

enum UnitFlags : uint32
Enumerator
UNIT_FLAG_SERVER_CONTROLLED 
UNIT_FLAG_NON_ATTACKABLE 
UNIT_FLAG_REMOVE_CLIENT_CONTROL 
UNIT_FLAG_PLAYER_CONTROLLED 
UNIT_FLAG_RENAME 
UNIT_FLAG_PREPARATION 
UNIT_FLAG_UNK_6 
UNIT_FLAG_NOT_ATTACKABLE_1 
UNIT_FLAG_IMMUNE_TO_PC 
UNIT_FLAG_IMMUNE_TO_NPC 
UNIT_FLAG_LOOTING 
UNIT_FLAG_PET_IN_COMBAT 
UNIT_FLAG_PVP 
UNIT_FLAG_SILENCED 
UNIT_FLAG_CANNOT_SWIM 
UNIT_FLAG_UNK_15 
UNIT_FLAG_NON_ATTACKABLE_2 
UNIT_FLAG_PACIFIED 
UNIT_FLAG_STUNNED 
UNIT_FLAG_IN_COMBAT 
UNIT_FLAG_TAXI_FLIGHT 
UNIT_FLAG_DISARMED 
UNIT_FLAG_CONFUSED 
UNIT_FLAG_FLEEING 
UNIT_FLAG_POSSESSED 
UNIT_FLAG_NOT_SELECTABLE 
UNIT_FLAG_SKINNABLE 
UNIT_FLAG_MOUNT 
UNIT_FLAG_UNK_28 
UNIT_FLAG_UNK_29 
UNIT_FLAG_SHEATHE 
UNIT_FLAG_UNK_31 
MAX_UNIT_FLAGS 
117  : uint32
118 {
119  UNIT_FLAG_SERVER_CONTROLLED = 0x00000001, // set only when unit movement is controlled by server - by SPLINE/MONSTER_MOVE packets, together with UNIT_FLAG_STUNNED; only set to units controlled by client; client function CGUnit_C::IsClientControlled returns false when set for owner
120  UNIT_FLAG_NON_ATTACKABLE = 0x00000002, // not attackable
121  UNIT_FLAG_REMOVE_CLIENT_CONTROL = 0x00000004, // This is a legacy flag used to disable movement player's movement while controlling other units, SMSG_CLIENT_CONTROL replaces this functionality clientside now. CONFUSED and FLEEING flags have the same effect on client movement asDISABLE_MOVE_CONTROL in addition to preventing spell casts/autoattack (they all allow climbing steeper hills and emotes while moving)
122  UNIT_FLAG_PLAYER_CONTROLLED = 0x00000008, // controlled by player, use _IMMUNE_TO_PC instead of _IMMUNE_TO_NPC
123  UNIT_FLAG_RENAME = 0x00000010,
124  UNIT_FLAG_PREPARATION = 0x00000020, // don't take reagents for spells with SPELL_ATTR5_NO_REAGENT_WHILE_PREP
125  UNIT_FLAG_UNK_6 = 0x00000040,
126  UNIT_FLAG_NOT_ATTACKABLE_1 = 0x00000080, // ?? (UNIT_FLAG_PLAYER_CONTROLLED | UNIT_FLAG_NOT_ATTACKABLE_1) is NON_PVP_ATTACKABLE
127  UNIT_FLAG_IMMUNE_TO_PC = 0x00000100, // disables combat/assistance with PlayerCharacters (PC) - see Unit::IsValidAttackTarget, Unit::IsValidAssistTarget
128  UNIT_FLAG_IMMUNE_TO_NPC = 0x00000200, // disables combat/assistance with NonPlayerCharacters (NPC) - see Unit::IsValidAttackTarget, Unit::IsValidAssistTarget
129  UNIT_FLAG_LOOTING = 0x00000400, // loot animation
130  UNIT_FLAG_PET_IN_COMBAT = 0x00000800, // on player pets: whether the pet is chasing a target to attack || on other units: whether any of the unit's minions is in combat
131  UNIT_FLAG_PVP = 0x00001000, // changed in 3.0.3
132  UNIT_FLAG_SILENCED = 0x00002000, // silenced, 2.1.1
133  UNIT_FLAG_CANNOT_SWIM = 0x00004000, // 2.0.8
134  UNIT_FLAG_UNK_15 = 0x00008000,
135  UNIT_FLAG_NON_ATTACKABLE_2 = 0x00010000, // removes attackable icon, if on yourself, cannot assist self but can cast TARGET_SELF spells - added by SPELL_AURA_MOD_UNATTACKABLE
136  UNIT_FLAG_PACIFIED = 0x00020000, // 3.0.3 ok
137  UNIT_FLAG_STUNNED = 0x00040000, // 3.0.3 ok
138  UNIT_FLAG_IN_COMBAT = 0x00080000,
139  UNIT_FLAG_TAXI_FLIGHT = 0x00100000, // disable casting at client side spell not allowed by taxi flight (mounted?), probably used with 0x4 flag
140  UNIT_FLAG_DISARMED = 0x00200000, // 3.0.3, disable melee spells casting..., "Required melee weapon" added to melee spells tooltip.
141  UNIT_FLAG_CONFUSED = 0x00400000,
142  UNIT_FLAG_FLEEING = 0x00800000,
143  UNIT_FLAG_POSSESSED = 0x01000000, // under direct client control by a player (possess or vehicle)
144  UNIT_FLAG_NOT_SELECTABLE = 0x02000000,
145  UNIT_FLAG_SKINNABLE = 0x04000000,
146  UNIT_FLAG_MOUNT = 0x08000000,
147  UNIT_FLAG_UNK_28 = 0x10000000,
148  UNIT_FLAG_UNK_29 = 0x20000000, // used in Feing Death spell
149  UNIT_FLAG_SHEATHE = 0x40000000,
150  UNIT_FLAG_UNK_31 = 0x80000000,
151  MAX_UNIT_FLAGS = 32
152 };
Definition: UnitDefines.h:132
Definition: UnitDefines.h:151
Definition: UnitDefines.h:124
Definition: UnitDefines.h:144
Definition: UnitDefines.h:142
Definition: UnitDefines.h:148
Definition: UnitDefines.h:130
Definition: UnitDefines.h:134
Definition: UnitDefines.h:131
Definition: UnitDefines.h:149
Definition: UnitDefines.h:150
Definition: UnitDefines.h:138
Definition: UnitDefines.h:128
Definition: UnitDefines.h:120
Definition: UnitDefines.h:126
Definition: UnitDefines.h:135
Definition: UnitDefines.h:121
uint32_t uint32
Definition: Define.h:152
Definition: UnitDefines.h:137
Definition: UnitDefines.h:125
Definition: UnitDefines.h:139
Definition: UnitDefines.h:136
Definition: UnitDefines.h:147
Definition: UnitDefines.h:141
Definition: UnitDefines.h:127
Definition: UnitDefines.h:122
Definition: UnitDefines.h:146
Definition: UnitDefines.h:143
Definition: UnitDefines.h:129
Definition: UnitDefines.h:123
Definition: UnitDefines.h:140
Definition: UnitDefines.h:145
Definition: UnitDefines.h:133
Definition: UnitDefines.h:119

◆ UnitFlags2

Enumerator
UNIT_FLAG2_FEIGN_DEATH 
UNIT_FLAG2_UNK1 
UNIT_FLAG2_IGNORE_REPUTATION 
UNIT_FLAG2_COMPREHEND_LANG 
UNIT_FLAG2_MIRROR_IMAGE 
UNIT_FLAG2_INSTANTLY_APPEAR_MODEL 
UNIT_FLAG2_FORCE_MOVEMENT 
UNIT_FLAG2_DISARM_OFFHAND 
UNIT_FLAG2_DISABLE_PRED_STATS 
UNIT_FLAG2_ALLOW_CHANGING_TALENTS 
UNIT_FLAG2_DISARM_RANGED 
UNIT_FLAG2_REGENERATE_POWER 
UNIT_FLAG2_RESTRICT_PARTY_INTERACTION 
UNIT_FLAG2_PREVENT_SPELL_CLICK 
UNIT_FLAG2_ALLOW_ENEMY_INTERACT 
UNIT_FLAG2_DISABLE_TURN 
UNIT_FLAG2_UNK2 
UNIT_FLAG2_PLAY_DEATH_ANIM 
UNIT_FLAG2_ALLOW_CHEAT_SPELLS 
UNIT_FLAG2_NO_ACTIONS 
MAX_UNIT_FLAGS_2 
155  : uint32
156 {
157  UNIT_FLAG2_FEIGN_DEATH = 0x00000001,
158  UNIT_FLAG2_UNK1 = 0x00000002, // Hide unit model (show only player equip)
159  UNIT_FLAG2_IGNORE_REPUTATION = 0x00000004,
160  UNIT_FLAG2_COMPREHEND_LANG = 0x00000008,
161  UNIT_FLAG2_MIRROR_IMAGE = 0x00000010,
162  UNIT_FLAG2_INSTANTLY_APPEAR_MODEL = 0x00000020, // Unit model instantly appears when summoned (does not fade in)
163  UNIT_FLAG2_FORCE_MOVEMENT = 0x00000040,
164  UNIT_FLAG2_DISARM_OFFHAND = 0x00000080,
165  UNIT_FLAG2_DISABLE_PRED_STATS = 0x00000100, // Player has disabled predicted stats (Used by raid frames)
166  UNIT_FLAG2_ALLOW_CHANGING_TALENTS = 0x00000200, // Allows changing talents outside rest area
167  UNIT_FLAG2_DISARM_RANGED = 0x00000400, // this does not disable ranged weapon display (maybe additional flag needed?)
168  UNIT_FLAG2_REGENERATE_POWER = 0x00000800,
169  UNIT_FLAG2_RESTRICT_PARTY_INTERACTION = 0x00001000, // Restrict interaction to party or raid
170  UNIT_FLAG2_PREVENT_SPELL_CLICK = 0x00002000, // Prevent spellclick
171  UNIT_FLAG2_ALLOW_ENEMY_INTERACT = 0x00004000,
172  UNIT_FLAG2_DISABLE_TURN = 0x00008000,
173  UNIT_FLAG2_UNK2 = 0x00010000,
174  UNIT_FLAG2_PLAY_DEATH_ANIM = 0x00020000, // Plays special death animation upon death
175  UNIT_FLAG2_ALLOW_CHEAT_SPELLS = 0x00040000, // Allows casting spells with AttributesEx7 & SPELL_ATTR7_IS_CHEAT_SPELL
176  UNIT_FLAG2_NO_ACTIONS = 0x00800000,
177  MAX_UNIT_FLAGS_2 = 19
178 };
Definition: UnitDefines.h:160
Definition: UnitDefines.h:169
Definition: UnitDefines.h:170
Definition: UnitDefines.h:174
Definition: UnitDefines.h:164
Definition: UnitDefines.h:162
Definition: UnitDefines.h:168
Definition: UnitDefines.h:171
Definition: UnitDefines.h:165
Definition: UnitDefines.h:157
Definition: UnitDefines.h:177
Definition: UnitDefines.h:175
Definition: UnitDefines.h:166
Definition: UnitDefines.h:158
uint32_t uint32
Definition: Define.h:152
Definition: UnitDefines.h:159
Definition: UnitDefines.h:167
Definition: UnitDefines.h:176
Definition: UnitDefines.h:161
Definition: UnitDefines.h:172
Definition: UnitDefines.h:163
Definition: UnitDefines.h:173

◆ UnitFlags3

Enumerator
UNIT_FLAG3_UNK1 
MAX_UNIT_FLAGS_3 
181  : uint32
182 {
183  UNIT_FLAG3_UNK1 = 0x00000001,
184  MAX_UNIT_FLAGS_3 = 1
185 };
Definition: UnitDefines.h:184
Definition: UnitDefines.h:183
uint32_t uint32
Definition: Define.h:152

◆ UnitMoveType

Enumerator
MOVE_WALK 
MOVE_RUN 
MOVE_RUN_BACK 
MOVE_SWIM 
MOVE_SWIM_BACK 
MOVE_TURN_RATE 
MOVE_FLIGHT 
MOVE_FLIGHT_BACK 
MOVE_PITCH_RATE 
102 {
103  MOVE_WALK = 0,
104  MOVE_RUN = 1,
105  MOVE_RUN_BACK = 2,
106  MOVE_SWIM = 3,
107  MOVE_SWIM_BACK = 4,
108  MOVE_TURN_RATE = 5,
109  MOVE_FLIGHT = 6,
110  MOVE_FLIGHT_BACK = 7,
111  MOVE_PITCH_RATE = 8
112 };
Definition: UnitDefines.h:103
Definition: UnitDefines.h:111
Definition: UnitDefines.h:109
Definition: UnitDefines.h:104
Definition: UnitDefines.h:106
Definition: UnitDefines.h:110
Definition: UnitDefines.h:108
Definition: UnitDefines.h:107
Definition: UnitDefines.h:105

◆ UnitPetFlag

Enumerator
UNIT_PET_FLAG_NONE 
UNIT_PET_FLAG_CAN_BE_RENAMED 
UNIT_PET_FLAG_CAN_BE_ABANDONED 
94  : uint8
95 {
96  UNIT_PET_FLAG_NONE = 0x0,
99 };
Definition: UnitDefines.h:96
Definition: UnitDefines.h:98
Definition: UnitDefines.h:97
uint8_t uint8
Definition: Define.h:154

◆ UnitPVPStateFlags

Enumerator
UNIT_BYTE2_FLAG_NONE 
UNIT_BYTE2_FLAG_PVP 
UNIT_BYTE2_FLAG_UNK1 
UNIT_BYTE2_FLAG_FFA_PVP 
UNIT_BYTE2_FLAG_SANCTUARY 
UNIT_BYTE2_FLAG_UNK4 
UNIT_BYTE2_FLAG_UNK5 
UNIT_BYTE2_FLAG_UNK6 
UNIT_BYTE2_FLAG_UNK7 
80  : uint8
81 {
82  UNIT_BYTE2_FLAG_NONE = 0x00,
83  UNIT_BYTE2_FLAG_PVP = 0x01,
84  UNIT_BYTE2_FLAG_UNK1 = 0x02,
87  UNIT_BYTE2_FLAG_UNK4 = 0x10,
88  UNIT_BYTE2_FLAG_UNK5 = 0x20,
89  UNIT_BYTE2_FLAG_UNK6 = 0x40,
91 };
Definition: UnitDefines.h:84
Definition: UnitDefines.h:82
Definition: UnitDefines.h:83
Definition: UnitDefines.h:87
Definition: UnitDefines.h:90
Definition: UnitDefines.h:86
Definition: UnitDefines.h:85
uint8_t uint8
Definition: Define.h:154
Definition: UnitDefines.h:88
Definition: UnitDefines.h:89

◆ UnitStandStateType

Enumerator
UNIT_STAND_STATE_STAND 
UNIT_STAND_STATE_SIT 
UNIT_STAND_STATE_SIT_CHAIR 
UNIT_STAND_STATE_SLEEP 
UNIT_STAND_STATE_SIT_LOW_CHAIR 
UNIT_STAND_STATE_SIT_MEDIUM_CHAIR 
UNIT_STAND_STATE_SIT_HIGH_CHAIR 
UNIT_STAND_STATE_DEAD 
UNIT_STAND_STATE_KNEEL 
UNIT_STAND_STATE_SUBMERGED 
34  : uint8
35 {
46 };
Definition: UnitDefines.h:37
Definition: UnitDefines.h:40
Definition: UnitDefines.h:43
Definition: UnitDefines.h:42
Definition: UnitDefines.h:41
Definition: UnitDefines.h:44
Definition: UnitDefines.h:39
Definition: UnitDefines.h:38
Definition: UnitDefines.h:45
uint8_t uint8
Definition: Define.h:154
Definition: UnitDefines.h:36

◆ UnitVisFlags

Enumerator
UNIT_VIS_FLAGS_UNK1 
UNIT_VIS_FLAGS_CREEP 
UNIT_VIS_FLAGS_UNTRACKABLE 
UNIT_VIS_FLAGS_UNK4 
UNIT_VIS_FLAGS_UNK5 
UNIT_VIS_FLAGS_ALL 
49  : uint8
50 {
51  UNIT_VIS_FLAGS_UNK1 = 0x01,
52  UNIT_VIS_FLAGS_CREEP = 0x02,
54  UNIT_VIS_FLAGS_UNK4 = 0x08,
55  UNIT_VIS_FLAGS_UNK5 = 0x10,
56  UNIT_VIS_FLAGS_ALL = 0xFF
57 };
Definition: UnitDefines.h:54
Definition: UnitDefines.h:55
Definition: UnitDefines.h:51
Definition: UnitDefines.h:53
Definition: UnitDefines.h:52
Definition: UnitDefines.h:56
uint8_t uint8
Definition: Define.h:154

Function Documentation

◆ DescribeReactState()

char const* DescribeReactState ( ReactStates  state)
inline
377 {
378  switch (state)
379  {
380  case REACT_PASSIVE: return "PASSIVE";
381  case REACT_DEFENSIVE: return "DEFENSIVE";
382  case REACT_AGGRESSIVE: return "AGGRESSIVE";
383  case REACT_ASSIST: return "ASSIST";
384  default: return "<Invalid react state>";
385  }
386 }
Definition: UnitDefines.h:371
Definition: UnitDefines.h:372
Definition: UnitDefines.h:370
Definition: UnitDefines.h:373
+ Here is the caller graph for this function: