TrinityCore
Loading...
Searching...
No Matches
RestMgr Class Reference

#include <RestMgr.h>

Public Member Functions

 RestMgr (Player *player)
 
 ~RestMgr ()
 
float GetRestBonus (RestTypes restType) const
 
void SetRestBonus (RestTypes restType, float restBonus)
 
void AddRestBonus (RestTypes restType, float restBonus)
 
bool HasRestFlag (RestFlag restFlag) const
 
void SetRestFlag (RestFlag restFlag)
 
void RemoveRestFlag (RestFlag restFlag)
 
uint32 GetRestBonusFor (RestTypes restType, uint32 xp)
 
Optional< InnAreaTriggerGetInnTrigger () const
 
void SetInnTrigger (Optional< InnAreaTrigger > trigger)
 
void Update (time_t now)
 
float CalcExtraPerSec (RestTypes restType, float bubble) const
 

Protected Member Functions

void LoadRestBonus (RestTypes restType, PlayerRestState state, float restBonus)
 

Private Attributes

Player_player
 
time_t _restTime
 
Optional< InnAreaTrigger_innAreaTrigger
 
float _restBonus [REST_TYPE_MAX]
 
uint32 _restFlagMask
 

Friends

class Player
 

Detailed Description

Definition at line 65 of file RestMgr.h.

Constructor & Destructor Documentation

◆ RestMgr()

RestMgr::RestMgr ( Player player)
explicit

Definition at line 26 of file RestMgr.cpp.

◆ ~RestMgr()

RestMgr::~RestMgr ( )
inline

Definition at line 70 of file RestMgr.h.

Member Function Documentation

◆ AddRestBonus()

void RestMgr::AddRestBonus ( RestTypes  restType,
float  restBonus 
)

Definition at line 85 of file RestMgr.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ CalcExtraPerSec()

float RestMgr::CalcExtraPerSec ( RestTypes  restType,
float  bubble 
) const

Definition at line 158 of file RestMgr.cpp.

+ Here is the caller graph for this function:

◆ GetInnTrigger()

Optional< InnAreaTrigger > RestMgr::GetInnTrigger ( ) const
inline

Definition at line 82 of file RestMgr.h.

◆ GetRestBonus()

float RestMgr::GetRestBonus ( RestTypes  restType) const
inline

Definition at line 72 of file RestMgr.h.

+ Here is the caller graph for this function:

◆ GetRestBonusFor()

uint32 RestMgr::GetRestBonusFor ( RestTypes  restType,
uint32  xp 
)

Definition at line 119 of file RestMgr.cpp.

+ Here is the call graph for this function:

◆ HasRestFlag()

bool RestMgr::HasRestFlag ( RestFlag  restFlag) const
inline

Definition at line 77 of file RestMgr.h.

◆ LoadRestBonus()

void RestMgr::LoadRestBonus ( RestTypes  restType,
PlayerRestState  state,
float  restBonus 
)
protected

Definition at line 151 of file RestMgr.cpp.

+ Here is the call graph for this function:

◆ RemoveRestFlag()

void RestMgr::RemoveRestFlag ( RestFlag  restFlag)

Definition at line 107 of file RestMgr.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SetInnTrigger()

void RestMgr::SetInnTrigger ( Optional< InnAreaTrigger trigger)
inline

Definition at line 83 of file RestMgr.h.

+ Here is the caller graph for this function:

◆ SetRestBonus()

void RestMgr::SetRestBonus ( RestTypes  restType,
float  restBonus 
)

Definition at line 32 of file RestMgr.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SetRestFlag()

void RestMgr::SetRestFlag ( RestFlag  restFlag)

Definition at line 95 of file RestMgr.cpp.

+ Here is the call graph for this function:

◆ Update()

void RestMgr::Update ( time_t  now)

Definition at line 136 of file RestMgr.cpp.

+ Here is the call graph for this function:

Friends And Related Symbol Documentation

◆ Player

friend class Player
friend

Definition at line 67 of file RestMgr.h.

Member Data Documentation

◆ _innAreaTrigger

Optional<InnAreaTrigger> RestMgr::_innAreaTrigger
private

Definition at line 95 of file RestMgr.h.

◆ _player

Player* RestMgr::_player
private

Definition at line 93 of file RestMgr.h.

◆ _restBonus

float RestMgr::_restBonus[REST_TYPE_MAX]
private

Definition at line 96 of file RestMgr.h.

◆ _restFlagMask

uint32 RestMgr::_restFlagMask
private

Definition at line 97 of file RestMgr.h.

◆ _restTime

time_t RestMgr::_restTime
private

Definition at line 94 of file RestMgr.h.


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