Show
Ignore:
Timestamp:
11/19/08 13:33:06 (17 years ago)
Author:
yumileroy
Message:

[svn] * Added some player info cache to the core. Thanx to Rognar for patch, visaglis for testing and bugging me to add it.

Original author: KingPin?
Date: 2008-10-21 12:43:24-05:00

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/game/ObjectMgr.h

    r85 r88  
    210210#define MAX_CONDITION                 11                    // maximum value in ConditionType enum 
    211211 
     212//Player's info 
     213typedef struct _tagCachePlayerInfo 
     214{ 
     215    std::string sPlayerName; 
     216    uint32 unfield; 
     217    uint32 unLevel; 
     218    uint8 unClass; 
     219//Arena 
     220    uint32 unArenaInfoId0; 
     221    uint32 unArenaInfoId1; 
     222    uint32 unArenaInfoId2; 
     223    uint32 unArenaInfoSlot0; 
     224    uint32 unArenaInfoSlot1; 
     225    uint32 unArenaInfoSlot2; 
     226}CachePlayerInfo, *PCachePlayerInfo; 
     227typedef HM_NAMESPACE::hash_map<uint32, PCachePlayerInfo> CachePlayerInfoMap; 
     228 
    212229struct PlayerCondition 
    213230{ 
     
    569586        uint32 GenerateItemTextID(); 
    570587        uint32 GeneratePetNumber(); 
     588         
     589        void LoadPlayerInfoInCache(); 
     590        PCachePlayerInfo GetPlayerInfoFromCache(uint32 unPlayerGuid) const; 
     591        CachePlayerInfoMap m_mPlayerInfoMap; 
    571592 
    572593        uint32 CreateItemText(std::string text);