TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
achievement_arena_kills Class Reference

Public Member Functions

 achievement_arena_kills (char const *name, uint8 arenaType)
 
bool OnCheck (Player *source, Unit *) override
 
- Public Member Functions inherited from ScriptObject
const std::string & GetName () const
 

Private Attributes

uint8 const _arenaType
 

Additional Inherited Members

- Protected Member Functions inherited from AchievementCriteriaScript
 AchievementCriteriaScript (const char *name)
 
- Protected Member Functions inherited from ScriptObject
 ScriptObject (const char *name)
 
virtual ~ScriptObject ()
 

Constructor & Destructor Documentation

achievement_arena_kills::achievement_arena_kills ( char const name,
uint8  arenaType 
)
inline
136  _arenaType(arenaType)
137  {
138  }
AchievementCriteriaScript(const char *name)
Definition: ScriptMgr.cpp:1658
uint8 const _arenaType
Definition: achievement_scripts.cpp:150

Member Function Documentation

bool achievement_arena_kills::OnCheck ( Player source,
Unit  
)
inlineoverridevirtual

Implements AchievementCriteriaScript.

141  {
142  // this checks GetBattleground() for NULL already
143  if (!source->InArena())
144  return false;
145 
146  return source->GetBattleground()->GetArenaType() == _arenaType;
147  }
uint8 const _arenaType
Definition: achievement_scripts.cpp:150

Member Data Documentation

uint8 const achievement_arena_kills::_arenaType
private

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