TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
StatSystem.cpp File Reference
#include "Unit.h"
#include "Player.h"
#include "Pet.h"
#include "Creature.h"
#include "SharedDefines.h"
#include "SpellAuras.h"
#include "SpellAuraEffects.h"
#include "World.h"
+ Include dependency graph for StatSystem.cpp:

Macros

#define ENTRY_IMP   416
 
#define ENTRY_VOIDWALKER   1860
 
#define ENTRY_SUCCUBUS   1863
 
#define ENTRY_FELHUNTER   417
 
#define ENTRY_FELGUARD   17252
 
#define ENTRY_WATER_ELEMENTAL   510
 
#define ENTRY_TREANT   1964
 
#define ENTRY_FIRE_ELEMENTAL   15438
 
#define ENTRY_GHOUL   26125
 
#define ENTRY_BLOODWORM   28017
 

Functions

bool _ModifyUInt32 (bool apply, uint32 &baseValue, int32 &amount)
 

Variables

const float m_diminishing_k [MAX_CLASSES]
 

Macro Definition Documentation

#define ENTRY_BLOODWORM   28017
#define ENTRY_FELGUARD   17252
#define ENTRY_FELHUNTER   417
#define ENTRY_FIRE_ELEMENTAL   15438
#define ENTRY_GHOUL   26125
#define ENTRY_IMP   416
#define ENTRY_SUCCUBUS   1863
#define ENTRY_TREANT   1964
#define ENTRY_VOIDWALKER   1860
#define ENTRY_WATER_ELEMENTAL   510

Function Documentation

bool _ModifyUInt32 ( bool  apply,
uint32 baseValue,
int32 amount 
)
inline
29 {
30  // If amount is negative, change sign and value of apply.
31  if (amount < 0)
32  {
33  apply = !apply;
34  amount = -amount;
35  }
36  if (apply)
37  baseValue += amount;
38  else
39  {
40  // Make sure we do not get uint32 overflow.
41  if (amount > int32(baseValue))
42  amount = baseValue;
43  baseValue -= amount;
44  }
45  return apply;
46 }
void apply(T *val)
Definition: ByteConverter.h:41
int32_t int32
Definition: g3dmath.h:167

+ Here is the call graph for this function:

Variable Documentation

const float m_diminishing_k[MAX_CLASSES]
Initial value:
=
{
0.9560f,
0.9560f,
0.9880f,
0.9880f,
0.9830f,
0.9560f,
0.9880f,
0.9830f,
0.9830f,
0.0f,
0.9720f
}