Otclient  14/8/2020
Game Class Reference

#include <game.h>

Public Member Functions

 Game ()
 
void init ()
 
void terminate ()
 
void loginWorld (const std::string &account, const std::string &password, const std::string &worldName, const std::string &worldHost, int worldPort, const std::string &characterName, const std::string &authenticatorToken, const std::string &sessionKey)
 
void cancelLogin ()
 
void forceLogout ()
 
void safeLogout ()
 
bool walk (Otc::Direction direction, bool dash=false)
 
bool dashWalk (Otc::Direction direction)
 
void autoWalk (std::vector< Otc::Direction > dirs)
 
void forceWalk (Otc::Direction direction)
 
void turn (Otc::Direction direction)
 
void stop ()
 
void look (const ThingPtr &thing, bool isBattleList=false)
 
void move (const ThingPtr &thing, const Position &toPos, int count)
 
void moveToParentContainer (const ThingPtr &thing, int count)
 
void rotate (const ThingPtr &thing)
 
void use (const ThingPtr &thing)
 
void useWith (const ItemPtr &item, const ThingPtr &toThing)
 
void useInventoryItem (int itemId)
 
void useInventoryItemWith (int itemId, const ThingPtr &toThing)
 
ItemPtr findItemInContainers (uint itemId, int subType)
 
int open (const ItemPtr &item, const ContainerPtr &previousContainer)
 
void openParent (const ContainerPtr &container)
 
void close (const ContainerPtr &container)
 
void refreshContainer (const ContainerPtr &container)
 
void attack (CreaturePtr creature)
 
void cancelAttack ()
 
void follow (CreaturePtr creature)
 
void cancelFollow ()
 
void cancelAttackAndFollow ()
 
void talk (const std::string &message)
 
void talkChannel (Otc::MessageMode mode, int channelId, const std::string &message)
 
void talkPrivate (Otc::MessageMode mode, const std::string &receiver, const std::string &message)
 
void openPrivateChannel (const std::string &receiver)
 
void requestChannels ()
 
void joinChannel (int channelId)
 
void leaveChannel (int channelId)
 
void closeNpcChannel ()
 
void openOwnChannel ()
 
void inviteToOwnChannel (const std::string &name)
 
void excludeFromOwnChannel (const std::string &name)
 
void partyInvite (int creatureId)
 
void partyJoin (int creatureId)
 
void partyRevokeInvitation (int creatureId)
 
void partyPassLeadership (int creatureId)
 
void partyLeave ()
 
void partyShareExperience (bool active)
 
void requestOutfit ()
 
void changeOutfit (const Outfit &outfit)
 
void addVip (const std::string &name)
 
void removeVip (int playerId)
 
void editVip (int playerId, const std::string &description, int iconId, bool notifyLogin)
 
void setChaseMode (Otc::ChaseModes chaseMode)
 
void setFightMode (Otc::FightModes fightMode)
 
void setSafeFight (bool on)
 
void setPVPMode (Otc::PVPModes pvpMode)
 
Otc::ChaseModes getChaseMode ()
 
Otc::FightModes getFightMode ()
 
bool isSafeFight ()
 
Otc::PVPModes getPVPMode ()
 
void setUnjustifiedPoints (UnjustifiedPoints unjustifiedPoints)
 
UnjustifiedPoints getUnjustifiedPoints ()
 
void setOpenPvpSituations (int openPvpSituations)
 
int getOpenPvpSituations ()
 
void inspectNpcTrade (const ItemPtr &item)
 
void buyItem (const ItemPtr &item, int amount, bool ignoreCapacity, bool buyWithBackpack)
 
void sellItem (const ItemPtr &item, int amount, bool ignoreEquipped)
 
void closeNpcTrade ()
 
void requestTrade (const ItemPtr &item, const CreaturePtr &creature)
 
void inspectTrade (bool counterOffer, int index)
 
void acceptTrade ()
 
void rejectTrade ()
 
void editText (uint id, const std::string &text)
 
void editList (uint id, int doorId, const std::string &text)
 
void openRuleViolation (const std::string &reporter)
 
void closeRuleViolation (const std::string &reporter)
 
void cancelRuleViolation ()
 
void reportBug (const std::string &comment)
 
void reportRuleViolation (const std::string &target, int reason, int action, const std::string &comment, const std::string &statement, int statementId, bool ipBanishment)
 
void debugReport (const std::string &a, const std::string &b, const std::string &c, const std::string &d)
 
void requestQuestLog ()
 
void requestQuestLine (int questId)
 
void equipItem (const ItemPtr &item)
 
void mount (bool mount)
 
void requestItemInfo (const ItemPtr &item, int index)
 
void answerModalDialog (uint32 dialog, int button, int choice)
 
void browseField (const Position &position)
 
void seekInContainer (int cid, int index)
 
void buyStoreOffer (int offerId, int productType, const std::string &name="")
 
void requestTransactionHistory (int page, int entriesPerPage)
 
void requestStoreOffers (const std::string &categoryName, int serviceType=0)
 
void openStore (int serviceType=0, const std::string &category="")
 
void transferCoins (const std::string &recipient, int amount)
 
void openTransactionHistory (int entriesPerPage)
 
void ping ()
 
void setPingDelay (int delay)
 
void changeMapAwareRange (int xrange, int yrange)
 
void enableFeature (Otc::GameFeature feature)
 
void disableFeature (Otc::GameFeature feature)
 
void setFeature (Otc::GameFeature feature, bool enabled)
 
bool getFeature (Otc::GameFeature feature)
 
void setProtocolVersion (int version)
 
int getProtocolVersion ()
 
void setClientVersion (int version)
 
int getClientVersion ()
 
void setCustomOs (int os)
 
int getOs ()
 
bool canPerformGameAction ()
 
bool checkBotProtection ()
 
bool isOnline ()
 
bool isLogging ()
 
bool isDead ()
 
bool isAttacking ()
 
bool isFollowing ()
 
bool isConnectionOk ()
 
int getPing ()
 
ContainerPtr getContainer (int index)
 
std::map< int, ContainerPtrgetContainers ()
 
std::map< int, VipgetVips ()
 
CreaturePtr getAttackingCreature ()
 
CreaturePtr getFollowingCreature ()
 
void setServerBeat (int beat)
 
int getServerBeat ()
 
void setCanReportBugs (bool enable)
 
bool canReportBugs ()
 
void setExpertPvpMode (bool enable)
 
bool getExpertPvpMode ()
 
LocalPlayerPtr getLocalPlayer ()
 
ProtocolGamePtr getProtocolGame ()
 
std::string getCharacterName ()
 
std::string getWorldName ()
 
std::vector< uint8getGMActions ()
 
bool isGM ()
 
Otc::Direction getLastWalkDir ()
 
std::string formatCreatureName (const std::string &name)
 
int findEmptyContainerId ()
 

Protected Member Functions

void processConnectionError (const boost::system::error_code &ec)
 
void processDisconnect ()
 
void processPing ()
 
void processPingBack ()
 
void processUpdateNeeded (const std::string &signature)
 
void processLoginError (const std::string &error)
 
void processLoginAdvice (const std::string &message)
 
void processLoginWait (const std::string &message, int time)
 
void processLoginToken (bool unknown)
 
void processLogin ()
 
void processPendingGame ()
 
void processEnterGame ()
 
void processGameStart ()
 
void processGameEnd ()
 
void processDeath (int deathType, int penality)
 
void processGMActions (const std::vector< uint8 > &actions)
 
void processInventoryChange (int slot, const ItemPtr &item)
 
void processAttackCancel (uint seq)
 
void processWalkCancel (Otc::Direction direction)
 
void processPlayerHelpers (int helpers)
 
void processPlayerModes (Otc::FightModes fightMode, Otc::ChaseModes chaseMode, bool safeMode, Otc::PVPModes pvpMode)
 
void processTextMessage (Otc::MessageMode mode, const std::string &text)
 
void processTalk (const std::string &name, int level, Otc::MessageMode mode, const std::string &text, int channelId, const Position &pos)
 
void processOpenContainer (int containerId, const ItemPtr &containerItem, const std::string &name, int capacity, bool hasParent, const std::vector< ItemPtr > &items, bool isUnlocked, bool hasPages, int containerSize, int firstIndex)
 
void processCloseContainer (int containerId)
 
void processContainerAddItem (int containerId, const ItemPtr &item, int slot)
 
void processContainerUpdateItem (int containerId, int slot, const ItemPtr &item)
 
void processContainerRemoveItem (int containerId, int slot, const ItemPtr &lastItem)
 
void processChannelList (const std::vector< std::tuple< int, std::string > > &channelList)
 
void processOpenChannel (int channelId, const std::string &name)
 
void processOpenPrivateChannel (const std::string &name)
 
void processOpenOwnPrivateChannel (int channelId, const std::string &name)
 
void processCloseChannel (int channelId)
 
void processRuleViolationChannel (int channelId)
 
void processRuleViolationRemove (const std::string &name)
 
void processRuleViolationCancel (const std::string &name)
 
void processRuleViolationLock ()
 
void processVipAdd (uint id, const std::string &name, uint status, const std::string &description, int iconId, bool notifyLogin)
 
void processVipStateChange (uint id, uint status)
 
void processTutorialHint (int id)
 
void processAddAutomapFlag (const Position &pos, int icon, const std::string &message)
 
void processRemoveAutomapFlag (const Position &pos, int icon, const std::string &message)
 
void processOpenOutfitWindow (const Outfit &currentOutfit, const std::vector< std::tuple< int, std::string, int > > &outfitList, const std::vector< std::tuple< int, std::string > > &mountList)
 
void processOpenNpcTrade (const std::vector< std::tuple< ItemPtr, std::string, int, int, int > > &items)
 
void processPlayerGoods (int money, const std::vector< std::tuple< ItemPtr, int > > &goods)
 
void processCloseNpcTrade ()
 
void processOwnTrade (const std::string &name, const std::vector< ItemPtr > &items)
 
void processCounterTrade (const std::string &name, const std::vector< ItemPtr > &items)
 
void processCloseTrade ()
 
void processEditText (uint id, int itemId, int maxLength, const std::string &text, const std::string &writer, const std::string &date)
 
void processEditList (uint id, int doorId, const std::string &text)
 
void processQuestLog (const std::vector< std::tuple< int, std::string, bool > > &questList)
 
void processQuestLine (int questId, const std::vector< std::tuple< std::string, std::string > > &questMissions)
 
void processModalDialog (uint32 id, std::string title, std::string message, std::vector< std::tuple< int, std::string > > buttonList, int enterButton, int escapeButton, std::vector< std::tuple< int, std::string > > choiceList, bool priority)
 
void enableBotCall ()
 
void disableBotCall ()
 

Friends

class ProtocolGame
 
class Map
 

Detailed Description

Definition at line 61 of file game.h.

Constructor & Destructor Documentation

◆ Game()

Game::Game ( )

Definition at line 39 of file game.cpp.

Member Function Documentation

◆ acceptTrade()

void Game::acceptTrade ( )

Definition at line 1283 of file game.cpp.

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

◆ addVip()

void Game::addVip ( const std::string &  name)

Definition at line 1134 of file game.cpp.

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

◆ answerModalDialog()

void Game::answerModalDialog ( uint32  dialog,
int  button,
int  choice 
)

Definition at line 1386 of file game.cpp.

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

◆ attack()

void Game::attack ( CreaturePtr  creature)

Definition at line 936 of file game.cpp.

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

◆ autoWalk()

void Game::autoWalk ( std::vector< Otc::Direction dirs)

Definition at line 678 of file game.cpp.

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

◆ browseField()

void Game::browseField ( const Position position)

Definition at line 1393 of file game.cpp.

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

◆ buyItem()

void Game::buyItem ( const ItemPtr item,
int  amount,
bool  ignoreCapacity,
bool  buyWithBackpack 
)

Definition at line 1248 of file game.cpp.

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

◆ buyStoreOffer()

void Game::buyStoreOffer ( int  offerId,
int  productType,
const std::string &  name = "" 
)

Definition at line 1407 of file game.cpp.

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

◆ cancelAttack()

void Game::cancelAttack ( )
inline

Definition at line 194 of file game.h.

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

◆ cancelAttackAndFollow()

void Game::cancelAttackAndFollow ( )

Definition at line 984 of file game.cpp.

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

◆ cancelFollow()

void Game::cancelFollow ( )
inline

Definition at line 196 of file game.h.

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

◆ cancelLogin()

void Game::cancelLogin ( )

Definition at line 551 of file game.cpp.

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

◆ cancelRuleViolation()

void Game::cancelRuleViolation ( )

Definition at line 1325 of file game.cpp.

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

◆ canPerformGameAction()

bool Game::canPerformGameAction ( )

Definition at line 1484 of file game.cpp.

Here is the call graph for this function:

◆ canReportBugs()

bool Game::canReportBugs ( )
inline

Definition at line 340 of file game.h.

Here is the caller graph for this function:

◆ changeMapAwareRange()

void Game::changeMapAwareRange ( int  xrange,
int  yrange 
)

Definition at line 1464 of file game.cpp.

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

◆ changeOutfit()

void Game::changeOutfit ( const Outfit outfit)

Definition at line 1127 of file game.cpp.

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

◆ checkBotProtection()

bool Game::checkBotProtection ( )

Definition at line 1471 of file game.cpp.

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

◆ close()

void Game::close ( const ContainerPtr container)

Definition at line 921 of file game.cpp.

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

◆ closeNpcChannel()

void Game::closeNpcChannel ( )

Definition at line 1050 of file game.cpp.

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

◆ closeNpcTrade()

void Game::closeNpcTrade ( )

Definition at line 1262 of file game.cpp.

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

◆ closeRuleViolation()

void Game::closeRuleViolation ( const std::string &  reporter)

Definition at line 1318 of file game.cpp.

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

◆ dashWalk()

bool Game::dashWalk ( Otc::Direction  direction)

Definition at line 673 of file game.cpp.

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

◆ debugReport()

void Game::debugReport ( const std::string &  a,
const std::string &  b,
const std::string &  c,
const std::string &  d 
)

Definition at line 1346 of file game.cpp.

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

◆ disableBotCall()

void Game::disableBotCall ( )
inlineprotected

Definition at line 356 of file game.h.

Here is the caller graph for this function:

◆ disableFeature()

void Game::disableFeature ( Otc::GameFeature  feature)
inline

Definition at line 308 of file game.h.

Here is the caller graph for this function:

◆ editList()

void Game::editList ( uint  id,
int  doorId,
const std::string &  text 
)

Definition at line 1304 of file game.cpp.

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

◆ editText()

void Game::editText ( uint  id,
const std::string &  text 
)

Definition at line 1297 of file game.cpp.

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

◆ editVip()

void Game::editVip ( int  playerId,
const std::string &  description,
int  iconId,
bool  notifyLogin 
)

Definition at line 1153 of file game.cpp.

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

◆ enableBotCall()

void Game::enableBotCall ( )
inlineprotected

Definition at line 355 of file game.h.

Here is the caller graph for this function:

◆ enableFeature()

void Game::enableFeature ( Otc::GameFeature  feature)
inline

Definition at line 307 of file game.h.

Here is the caller graph for this function:

◆ equipItem()

void Game::equipItem ( const ItemPtr item)

Definition at line 1365 of file game.cpp.

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

◆ excludeFromOwnChannel()

void Game::excludeFromOwnChannel ( const std::string &  name)

Definition at line 1071 of file game.cpp.

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

◆ findEmptyContainerId()

int Game::findEmptyContainerId ( )

Definition at line 1731 of file game.cpp.

Here is the caller graph for this function:

◆ findItemInContainers()

ItemPtr Game::findItemInContainers ( uint  itemId,
int  subType 
)

Definition at line 884 of file game.cpp.

Here is the caller graph for this function:

◆ follow()

void Game::follow ( CreaturePtr  creature)

Definition at line 960 of file game.cpp.

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

◆ forceLogout()

void Game::forceLogout ( )

Definition at line 560 of file game.cpp.

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

◆ forceWalk()

void Game::forceWalk ( Otc::Direction  direction)

Definition at line 716 of file game.cpp.

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

◆ formatCreatureName()

std::string Game::formatCreatureName ( const std::string &  name)

Definition at line 1713 of file game.cpp.

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

◆ getAttackingCreature()

CreaturePtr Game::getAttackingCreature ( )
inline

Definition at line 335 of file game.h.

Here is the caller graph for this function:

◆ getCharacterName()

std::string Game::getCharacterName ( )
inline

Definition at line 345 of file game.h.

Here is the caller graph for this function:

◆ getChaseMode()

Otc::ChaseModes Game::getChaseMode ( )
inline

Definition at line 236 of file game.h.

Here is the caller graph for this function:

◆ getClientVersion()

int Game::getClientVersion ( )
inline

Definition at line 316 of file game.h.

Here is the caller graph for this function:

◆ getContainer()

ContainerPtr Game::getContainer ( int  index)
inline

Definition at line 332 of file game.h.

Here is the caller graph for this function:

◆ getContainers()

std::map<int, ContainerPtr> Game::getContainers ( )
inline

Definition at line 333 of file game.h.

Here is the caller graph for this function:

◆ getExpertPvpMode()

bool Game::getExpertPvpMode ( )
inline

Definition at line 342 of file game.h.

◆ getFeature()

bool Game::getFeature ( Otc::GameFeature  feature)
inline

Definition at line 310 of file game.h.

Here is the caller graph for this function:

◆ getFightMode()

Otc::FightModes Game::getFightMode ( )
inline

Definition at line 237 of file game.h.

Here is the caller graph for this function:

◆ getFollowingCreature()

CreaturePtr Game::getFollowingCreature ( )
inline

Definition at line 336 of file game.h.

Here is the caller graph for this function:

◆ getGMActions()

std::vector<uint8> Game::getGMActions ( )
inline

Definition at line 347 of file game.h.

Here is the caller graph for this function:

◆ getLastWalkDir()

Otc::Direction Game::getLastWalkDir ( )
inline

Definition at line 349 of file game.h.

Here is the caller graph for this function:

◆ getLocalPlayer()

LocalPlayerPtr Game::getLocalPlayer ( )
inline

Definition at line 343 of file game.h.

Here is the caller graph for this function:

◆ getOpenPvpSituations()

int Game::getOpenPvpSituations ( )
inline

Definition at line 245 of file game.h.

Here is the caller graph for this function:

◆ getOs()

int Game::getOs ( )

Definition at line 1739 of file game.cpp.

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

◆ getPing()

int Game::getPing ( )
inline

Definition at line 331 of file game.h.

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

◆ getProtocolGame()

ProtocolGamePtr Game::getProtocolGame ( )
inline

Definition at line 344 of file game.h.

Here is the caller graph for this function:

◆ getProtocolVersion()

int Game::getProtocolVersion ( )
inline

Definition at line 313 of file game.h.

Here is the caller graph for this function:

◆ getPVPMode()

Otc::PVPModes Game::getPVPMode ( )
inline

Definition at line 239 of file game.h.

Here is the caller graph for this function:

◆ getServerBeat()

int Game::getServerBeat ( )
inline

Definition at line 338 of file game.h.

Here is the caller graph for this function:

◆ getUnjustifiedPoints()

UnjustifiedPoints Game::getUnjustifiedPoints ( )
inline

Definition at line 243 of file game.h.

Here is the caller graph for this function:

◆ getVips()

std::map<int, Vip> Game::getVips ( )
inline

Definition at line 334 of file game.h.

Here is the caller graph for this function:

◆ getWorldName()

std::string Game::getWorldName ( )
inline

Definition at line 346 of file game.h.

Here is the caller graph for this function:

◆ init()

void Game::init ( )

Definition at line 58 of file game.cpp.

Here is the caller graph for this function:

◆ inspectNpcTrade()

void Game::inspectNpcTrade ( const ItemPtr item)

Definition at line 1241 of file game.cpp.

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

◆ inspectTrade()

void Game::inspectTrade ( bool  counterOffer,
int  index 
)

Definition at line 1276 of file game.cpp.

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

◆ inviteToOwnChannel()

void Game::inviteToOwnChannel ( const std::string &  name)

Definition at line 1064 of file game.cpp.

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

◆ isAttacking()

bool Game::isAttacking ( )
inline

Definition at line 327 of file game.h.

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

◆ isConnectionOk()

bool Game::isConnectionOk ( )
inline

Definition at line 329 of file game.h.

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

◆ isDead()

bool Game::isDead ( )
inline

Definition at line 326 of file game.h.

Here is the caller graph for this function:

◆ isFollowing()

bool Game::isFollowing ( )
inline

Definition at line 328 of file game.h.

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

◆ isGM()

bool Game::isGM ( )
inline

Definition at line 348 of file game.h.

Here is the caller graph for this function:

◆ isLogging()

bool Game::isLogging ( )
inline

Definition at line 325 of file game.h.

Here is the caller graph for this function:

◆ isOnline()

bool Game::isOnline ( )
inline

Definition at line 324 of file game.h.

Here is the caller graph for this function:

◆ isSafeFight()

bool Game::isSafeFight ( )
inline

Definition at line 238 of file game.h.

Here is the caller graph for this function:

◆ joinChannel()

void Game::joinChannel ( int  channelId)

Definition at line 1036 of file game.cpp.

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

◆ leaveChannel()

void Game::leaveChannel ( int  channelId)

Definition at line 1043 of file game.cpp.

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

◆ loginWorld()

void Game::loginWorld ( const std::string &  account,
const std::string &  password,
const std::string &  worldName,
const std::string &  worldHost,
int  worldPort,
const std::string &  characterName,
const std::string &  authenticatorToken,
const std::string &  sessionKey 
)

Definition at line 531 of file game.cpp.

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

◆ look()

void Game::look ( const ThingPtr thing,
bool  isBattleList = false 
)

Definition at line 787 of file game.cpp.

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

◆ mount()

void Game::mount ( bool  mount)

Definition at line 1372 of file game.cpp.

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

◆ move()

void Game::move ( const ThingPtr thing,
const Position toPos,
int  count 
)

Definition at line 798 of file game.cpp.

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

◆ moveToParentContainer()

void Game::moveToParentContainer ( const ThingPtr thing,
int  count 
)

Definition at line 815 of file game.cpp.

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

◆ open()

int Game::open ( const ItemPtr item,
const ContainerPtr previousContainer 
)

Definition at line 898 of file game.cpp.

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

◆ openOwnChannel()

void Game::openOwnChannel ( )

Definition at line 1057 of file game.cpp.

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

◆ openParent()

void Game::openParent ( const ContainerPtr container)

Definition at line 913 of file game.cpp.

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

◆ openPrivateChannel()

void Game::openPrivateChannel ( const std::string &  receiver)

Definition at line 1022 of file game.cpp.

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

◆ openRuleViolation()

void Game::openRuleViolation ( const std::string &  reporter)

Definition at line 1311 of file game.cpp.

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

◆ openStore()

void Game::openStore ( int  serviceType = 0,
const std::string &  category = "" 
)

Definition at line 1428 of file game.cpp.

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

◆ openTransactionHistory()

void Game::openTransactionHistory ( int  entriesPerPage)

Definition at line 1442 of file game.cpp.

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

◆ partyInvite()

void Game::partyInvite ( int  creatureId)

Definition at line 1078 of file game.cpp.

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

◆ partyJoin()

void Game::partyJoin ( int  creatureId)

Definition at line 1085 of file game.cpp.

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

◆ partyLeave()

void Game::partyLeave ( )

Definition at line 1106 of file game.cpp.

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

◆ partyPassLeadership()

void Game::partyPassLeadership ( int  creatureId)

Definition at line 1099 of file game.cpp.

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

◆ partyRevokeInvitation()

void Game::partyRevokeInvitation ( int  creatureId)

Definition at line 1092 of file game.cpp.

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

◆ partyShareExperience()

void Game::partyShareExperience ( bool  active)

Definition at line 1113 of file game.cpp.

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

◆ ping()

void Game::ping ( )

Definition at line 1449 of file game.cpp.

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

◆ processAddAutomapFlag()

void Game::processAddAutomapFlag ( const Position pos,
int  icon,
const std::string &  message 
)
protected

Definition at line 424 of file game.cpp.

Here is the call graph for this function:

◆ processAttackCancel()

void Game::processAttackCancel ( uint  seq)
protected

Definition at line 520 of file game.cpp.

Here is the call graph for this function:

◆ processChannelList()

void Game::processChannelList ( const std::vector< std::tuple< int, std::string > > &  channelList)
protected

Definition at line 362 of file game.cpp.

Here is the call graph for this function:

◆ processCloseChannel()

void Game::processCloseChannel ( int  channelId)
protected

Definition at line 382 of file game.cpp.

Here is the call graph for this function:

◆ processCloseContainer()

void Game::processCloseContainer ( int  containerId)
protected

Definition at line 313 of file game.cpp.

Here is the call graph for this function:

◆ processCloseNpcTrade()

void Game::processCloseNpcTrade ( )
protected

Definition at line 475 of file game.cpp.

Here is the call graph for this function:

◆ processCloseTrade()

void Game::processCloseTrade ( )
protected

Definition at line 490 of file game.cpp.

Here is the call graph for this function:

◆ processConnectionError()

void Game::processConnectionError ( const boost::system::error_code &  ec)
protected

Definition at line 116 of file game.cpp.

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

◆ processContainerAddItem()

void Game::processContainerAddItem ( int  containerId,
const ItemPtr item,
int  slot 
)
protected

Definition at line 324 of file game.cpp.

Here is the call graph for this function:

◆ processContainerRemoveItem()

void Game::processContainerRemoveItem ( int  containerId,
int  slot,
const ItemPtr lastItem 
)
protected

Definition at line 344 of file game.cpp.

Here is the call graph for this function:

◆ processContainerUpdateItem()

void Game::processContainerUpdateItem ( int  containerId,
int  slot,
const ItemPtr item 
)
protected

Definition at line 334 of file game.cpp.

Here is the call graph for this function:

◆ processCounterTrade()

void Game::processCounterTrade ( const std::string &  name,
const std::vector< ItemPtr > &  items 
)
protected

Definition at line 485 of file game.cpp.

Here is the call graph for this function:

◆ processDeath()

void Game::processDeath ( int  deathType,
int  penality 
)
protected

Definition at line 231 of file game.cpp.

Here is the call graph for this function:

◆ processDisconnect()

void Game::processDisconnect ( )
protected

Definition at line 128 of file game.cpp.

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

◆ processEditList()

void Game::processEditList ( uint  id,
int  doorId,
const std::string &  text 
)
protected

Definition at line 500 of file game.cpp.

Here is the call graph for this function:

◆ processEditText()

void Game::processEditText ( uint  id,
int  itemId,
int  maxLength,
const std::string &  text,
const std::string &  writer,
const std::string &  date 
)
protected

Definition at line 495 of file game.cpp.

Here is the call graph for this function:

◆ processEnterGame()

void Game::processEnterGame ( )
protected

Definition at line 176 of file game.cpp.

Here is the call graph for this function:

◆ processGameEnd()

void Game::processGameEnd ( )
protected

Definition at line 211 of file game.cpp.

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

◆ processGameStart()

void Game::processGameStart ( )
protected

Definition at line 182 of file game.cpp.

Here is the call graph for this function:

◆ processGMActions()

void Game::processGMActions ( const std::vector< uint8 > &  actions)
protected

Definition at line 239 of file game.cpp.

Here is the call graph for this function:

◆ processInventoryChange()

void Game::processInventoryChange ( int  slot,
const ItemPtr item 
)
protected

Definition at line 354 of file game.cpp.

Here is the call graph for this function:

◆ processLogin()

void Game::processLogin ( )
protected

Definition at line 164 of file game.cpp.

Here is the call graph for this function:

◆ processLoginAdvice()

void Game::processLoginAdvice ( const std::string &  message)
protected

Definition at line 149 of file game.cpp.

Here is the call graph for this function:

◆ processLoginError()

void Game::processLoginError ( const std::string &  error)
protected

Definition at line 144 of file game.cpp.

Here is the call graph for this function:

◆ processLoginToken()

void Game::processLoginToken ( bool  unknown)
protected

Definition at line 159 of file game.cpp.

Here is the call graph for this function:

◆ processLoginWait()

void Game::processLoginWait ( const std::string &  message,
int  time 
)
protected

Definition at line 154 of file game.cpp.

Here is the call graph for this function:

◆ processModalDialog()

void Game::processModalDialog ( uint32  id,
std::string  title,
std::string  message,
std::vector< std::tuple< int, std::string > >  buttonList,
int  enterButton,
int  escapeButton,
std::vector< std::tuple< int, std::string > >  choiceList,
bool  priority 
)
protected

Definition at line 515 of file game.cpp.

Here is the call graph for this function:

◆ processOpenChannel()

void Game::processOpenChannel ( int  channelId,
const std::string &  name 
)
protected

Definition at line 367 of file game.cpp.

Here is the call graph for this function:

◆ processOpenContainer()

void Game::processOpenContainer ( int  containerId,
const ItemPtr containerItem,
const std::string &  name,
int  capacity,
bool  hasParent,
const std::vector< ItemPtr > &  items,
bool  isUnlocked,
bool  hasPages,
int  containerSize,
int  firstIndex 
)
protected

Definition at line 297 of file game.cpp.

Here is the call graph for this function:

◆ processOpenNpcTrade()

void Game::processOpenNpcTrade ( const std::vector< std::tuple< ItemPtr, std::string, int, int, int > > &  items)
protected

Definition at line 465 of file game.cpp.

Here is the call graph for this function:

◆ processOpenOutfitWindow()

void Game::processOpenOutfitWindow ( const Outfit currentOutfit,
const std::vector< std::tuple< int, std::string, int > > &  outfitList,
const std::vector< std::tuple< int, std::string > > &  mountList 
)
protected

Definition at line 434 of file game.cpp.

Here is the call graph for this function:

◆ processOpenOwnPrivateChannel()

void Game::processOpenOwnPrivateChannel ( int  channelId,
const std::string &  name 
)
protected

Definition at line 377 of file game.cpp.

Here is the call graph for this function:

◆ processOpenPrivateChannel()

void Game::processOpenPrivateChannel ( const std::string &  name)
protected

Definition at line 372 of file game.cpp.

Here is the call graph for this function:

◆ processOwnTrade()

void Game::processOwnTrade ( const std::string &  name,
const std::vector< ItemPtr > &  items 
)
protected

Definition at line 480 of file game.cpp.

Here is the call graph for this function:

◆ processPendingGame()

void Game::processPendingGame ( )
protected

Definition at line 169 of file game.cpp.

Here is the call graph for this function:

◆ processPing()

void Game::processPing ( )
protected

Definition at line 263 of file game.cpp.

Here is the call graph for this function:

◆ processPingBack()

void Game::processPingBack ( )
protected

Definition at line 271 of file game.cpp.

Here is the call graph for this function:

◆ processPlayerGoods()

void Game::processPlayerGoods ( int  money,
const std::vector< std::tuple< ItemPtr, int > > &  goods 
)
protected

Definition at line 470 of file game.cpp.

Here is the call graph for this function:

◆ processPlayerHelpers()

void Game::processPlayerHelpers ( int  helpers)
protected

Definition at line 245 of file game.cpp.

Here is the call graph for this function:

◆ processPlayerModes()

void Game::processPlayerModes ( Otc::FightModes  fightMode,
Otc::ChaseModes  chaseMode,
bool  safeMode,
Otc::PVPModes  pvpMode 
)
protected

Definition at line 250 of file game.cpp.

Here is the call graph for this function:

◆ processQuestLine()

void Game::processQuestLine ( int  questId,
const std::vector< std::tuple< std::string, std::string > > &  questMissions 
)
protected

Definition at line 510 of file game.cpp.

Here is the call graph for this function:

◆ processQuestLog()

void Game::processQuestLog ( const std::vector< std::tuple< int, std::string, bool > > &  questList)
protected

Definition at line 505 of file game.cpp.

Here is the call graph for this function:

◆ processRemoveAutomapFlag()

void Game::processRemoveAutomapFlag ( const Position pos,
int  icon,
const std::string &  message 
)
protected

Definition at line 429 of file game.cpp.

Here is the call graph for this function:

◆ processRuleViolationCancel()

void Game::processRuleViolationCancel ( const std::string &  name)
protected

Definition at line 397 of file game.cpp.

Here is the call graph for this function:

◆ processRuleViolationChannel()

void Game::processRuleViolationChannel ( int  channelId)
protected

Definition at line 387 of file game.cpp.

Here is the call graph for this function:

◆ processRuleViolationLock()

void Game::processRuleViolationLock ( )
protected

Definition at line 402 of file game.cpp.

Here is the call graph for this function:

◆ processRuleViolationRemove()

void Game::processRuleViolationRemove ( const std::string &  name)
protected

Definition at line 392 of file game.cpp.

Here is the call graph for this function:

◆ processTalk()

void Game::processTalk ( const std::string &  name,
int  level,
Otc::MessageMode  mode,
const std::string &  text,
int  channelId,
const Position pos 
)
protected

Definition at line 292 of file game.cpp.

Here is the call graph for this function:

◆ processTextMessage()

void Game::processTextMessage ( Otc::MessageMode  mode,
const std::string &  text 
)
protected

Definition at line 287 of file game.cpp.

Here is the call graph for this function:

◆ processTutorialHint()

void Game::processTutorialHint ( int  id)
protected

Definition at line 419 of file game.cpp.

Here is the call graph for this function:

◆ processUpdateNeeded()

void Game::processUpdateNeeded ( const std::string &  signature)
protected

Definition at line 139 of file game.cpp.

Here is the call graph for this function:

◆ processVipAdd()

void Game::processVipAdd ( uint  id,
const std::string &  name,
uint  status,
const std::string &  description,
int  iconId,
bool  notifyLogin 
)
protected

Definition at line 407 of file game.cpp.

Here is the call graph for this function:

◆ processVipStateChange()

void Game::processVipStateChange ( uint  id,
uint  status 
)
protected

Definition at line 413 of file game.cpp.

Here is the call graph for this function:

◆ processWalkCancel()

void Game::processWalkCancel ( Otc::Direction  direction)
protected

Definition at line 526 of file game.cpp.

Here is the call graph for this function:

◆ refreshContainer()

void Game::refreshContainer ( const ContainerPtr container)

Definition at line 929 of file game.cpp.

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

◆ rejectTrade()

void Game::rejectTrade ( )

Definition at line 1290 of file game.cpp.

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

◆ removeVip()

void Game::removeVip ( int  playerId)

Definition at line 1141 of file game.cpp.

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

◆ reportBug()

void Game::reportBug ( const std::string &  comment)

Definition at line 1332 of file game.cpp.

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

◆ reportRuleViolation()

void Game::reportRuleViolation ( const std::string &  target,
int  reason,
int  action,
const std::string &  comment,
const std::string &  statement,
int  statementId,
bool  ipBanishment 
)

Definition at line 1339 of file game.cpp.

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

◆ requestChannels()

void Game::requestChannels ( )

Definition at line 1029 of file game.cpp.

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

◆ requestItemInfo()

void Game::requestItemInfo ( const ItemPtr item,
int  index 
)

Definition at line 1379 of file game.cpp.

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

◆ requestOutfit()

void Game::requestOutfit ( )

Definition at line 1120 of file game.cpp.

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

◆ requestQuestLine()

void Game::requestQuestLine ( int  questId)

Definition at line 1358 of file game.cpp.

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

◆ requestQuestLog()

void Game::requestQuestLog ( )

Definition at line 1351 of file game.cpp.

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

◆ requestStoreOffers()

void Game::requestStoreOffers ( const std::string &  categoryName,
int  serviceType = 0 
)

Definition at line 1421 of file game.cpp.

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

◆ requestTrade()

void Game::requestTrade ( const ItemPtr item,
const CreaturePtr creature 
)

Definition at line 1269 of file game.cpp.

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

◆ requestTransactionHistory()

void Game::requestTransactionHistory ( int  page,
int  entriesPerPage 
)

Definition at line 1414 of file game.cpp.

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

◆ rotate()

void Game::rotate ( const ThingPtr thing)

Definition at line 824 of file game.cpp.

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

◆ safeLogout()

void Game::safeLogout ( )

Definition at line 569 of file game.cpp.

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

◆ seekInContainer()

void Game::seekInContainer ( int  cid,
int  index 
)

Definition at line 1400 of file game.cpp.

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

◆ sellItem()

void Game::sellItem ( const ItemPtr item,
int  amount,
bool  ignoreEquipped 
)

Definition at line 1255 of file game.cpp.

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

◆ setCanReportBugs()

void Game::setCanReportBugs ( bool  enable)
inline

Definition at line 339 of file game.h.

◆ setChaseMode()

void Game::setChaseMode ( Otc::ChaseModes  chaseMode)

Definition at line 1170 of file game.cpp.

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

◆ setClientVersion()

void Game::setClientVersion ( int  version)

Definition at line 1514 of file game.cpp.

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

◆ setCustomOs()

void Game::setCustomOs ( int  os)
inline

Definition at line 318 of file game.h.

Here is the caller graph for this function:

◆ setExpertPvpMode()

void Game::setExpertPvpMode ( bool  enable)
inline

Definition at line 341 of file game.h.

◆ setFeature()

void Game::setFeature ( Otc::GameFeature  feature,
bool  enabled 
)
inline

Definition at line 309 of file game.h.

Here is the caller graph for this function:

◆ setFightMode()

void Game::setFightMode ( Otc::FightModes  fightMode)

Definition at line 1181 of file game.cpp.

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

◆ setOpenPvpSituations()

void Game::setOpenPvpSituations ( int  openPvpSituations)

Definition at line 1229 of file game.cpp.

Here is the call graph for this function:

◆ setPingDelay()

void Game::setPingDelay ( int  delay)
inline

Definition at line 301 of file game.h.

Here is the caller graph for this function:

◆ setProtocolVersion()

void Game::setProtocolVersion ( int  version)

Definition at line 1496 of file game.cpp.

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

◆ setPVPMode()

void Game::setPVPMode ( Otc::PVPModes  pvpMode)

Definition at line 1203 of file game.cpp.

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

◆ setSafeFight()

void Game::setSafeFight ( bool  on)

Definition at line 1192 of file game.cpp.

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

◆ setServerBeat()

void Game::setServerBeat ( int  beat)
inline

Definition at line 337 of file game.h.

◆ setUnjustifiedPoints()

void Game::setUnjustifiedPoints ( UnjustifiedPoints  unjustifiedPoints)

Definition at line 1216 of file game.cpp.

Here is the call graph for this function:

◆ stop()

void Game::stop ( )

Definition at line 776 of file game.cpp.

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

◆ talk()

void Game::talk ( const std::string &  message)

Definition at line 1001 of file game.cpp.

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

◆ talkChannel()

void Game::talkChannel ( Otc::MessageMode  mode,
int  channelId,
const std::string &  message 
)

Definition at line 1008 of file game.cpp.

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

◆ talkPrivate()

void Game::talkPrivate ( Otc::MessageMode  mode,
const std::string &  receiver,
const std::string &  message 
)

Definition at line 1015 of file game.cpp.

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

◆ terminate()

void Game::terminate ( )

Definition at line 63 of file game.cpp.

Here is the caller graph for this function:

◆ transferCoins()

void Game::transferCoins ( const std::string &  recipient,
int  amount 
)

Definition at line 1435 of file game.cpp.

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

◆ turn()

void Game::turn ( Otc::Direction  direction)

Definition at line 753 of file game.cpp.

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

◆ use()

void Game::use ( const ThingPtr thing)

Definition at line 832 of file game.cpp.

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

◆ useInventoryItem()

void Game::useInventoryItem ( int  itemId)

Definition at line 846 of file game.cpp.

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

◆ useInventoryItemWith()

void Game::useInventoryItemWith ( int  itemId,
const ThingPtr toThing 
)

Definition at line 871 of file game.cpp.

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

◆ useWith()

void Game::useWith ( const ItemPtr item,
const ThingPtr toThing 
)

Definition at line 856 of file game.cpp.

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

◆ walk()

bool Game::walk ( Otc::Direction  direction,
bool  dash = false 
)

Definition at line 577 of file game.cpp.

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

Friends And Related Function Documentation

◆ Map

friend class Map
friend

Definition at line 158 of file game.h.

◆ ProtocolGame

friend class ProtocolGame
friend

Definition at line 157 of file game.h.


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