mirror of
https://github.com/mangosfour/server.git
synced 2025-12-30 01:37:03 +00:00
[7393] Implement access to client side holiday ids.
* src/game/GameEvent.* renamed to src/game/GameEventMgr.* for consistence * `game_event` now have new `holiday` field for store client side holiday id associated with game event * Added new enum HolidayIds with existed at this moment holiday ids. * New function "bool IsHolidayActive(HolidayIds id)" added accessabel from scripts for active holidays check.
This commit is contained in:
parent
4523a47155
commit
be74937146
19 changed files with 162 additions and 62 deletions
|
|
@ -75,6 +75,7 @@ DBCStorage <GtOCTRegenHPEntry> sGtOCTRegenHPStore(GtOCTRegenHPfmt);
|
|||
//DBCStorage <GtOCTRegenMPEntry> sGtOCTRegenMPStore(GtOCTRegenMPfmt); -- not used currently
|
||||
DBCStorage <GtRegenHPPerSptEntry> sGtRegenHPPerSptStore(GtRegenHPPerSptfmt);
|
||||
DBCStorage <GtRegenMPPerSptEntry> sGtRegenMPPerSptStore(GtRegenMPPerSptfmt);
|
||||
DBCStorage <HolidaysEntry> sHolidaysStore(Holidaysfmt);
|
||||
DBCStorage <ItemEntry> sItemStore(Itemfmt);
|
||||
//DBCStorage <ItemCondExtCostsEntry> sItemCondExtCostsStore(ItemCondExtCostsEntryfmt);
|
||||
//DBCStorage <ItemDisplayInfoEntry> sItemDisplayInfoStore(ItemDisplayTemplateEntryfmt); -- not used currently
|
||||
|
|
@ -193,7 +194,7 @@ void LoadDBCStores(const std::string& dataPath)
|
|||
{
|
||||
std::string dbcPath = dataPath+"dbc/";
|
||||
|
||||
const uint32 DBCFilesCount = 72;
|
||||
const uint32 DBCFilesCount = 73;
|
||||
|
||||
barGoLink bar( DBCFilesCount );
|
||||
|
||||
|
|
@ -266,6 +267,7 @@ void LoadDBCStores(const std::string& dataPath)
|
|||
//LoadDBC(availableDbcLocales,bar,bad_dbc_files,sGtOCTRegenMPStore, dbcPath,"gtOCTRegenMP.dbc"); -- not used currently
|
||||
LoadDBC(availableDbcLocales,bar,bad_dbc_files,sGtRegenHPPerSptStore, dbcPath,"gtRegenHPPerSpt.dbc");
|
||||
LoadDBC(availableDbcLocales,bar,bad_dbc_files,sGtRegenMPPerSptStore, dbcPath,"gtRegenMPPerSpt.dbc");
|
||||
LoadDBC(availableDbcLocales,bar,bad_dbc_files,sHolidaysStore, dbcPath,"Holidays.dbc");
|
||||
LoadDBC(availableDbcLocales,bar,bad_dbc_files,sItemStore, dbcPath,"Item.dbc");
|
||||
//LoadDBC(availableDbcLocales,bar,bad_dbc_files,sItemDisplayInfoStore, dbcPath,"ItemDisplayInfo.dbc"); -- not used currently
|
||||
//LoadDBC(availableDbcLocales,bar,bad_dbc_files,sItemCondExtCostsStore, dbcPath,"ItemCondExtCosts.dbc");
|
||||
|
|
|
|||
|
|
@ -167,6 +167,7 @@ extern DBCStorage <GtOCTRegenHPEntry> sGtOCTRegenHPStore;
|
|||
//extern DBCStorage <GtOCTRegenMPEntry> sGtOCTRegenMPStore; -- not used currently
|
||||
extern DBCStorage <GtRegenHPPerSptEntry> sGtRegenHPPerSptStore;
|
||||
extern DBCStorage <GtRegenMPPerSptEntry> sGtRegenMPPerSptStore;
|
||||
extern DBCStorage <HolidaysEntry> sHolidaysStore;
|
||||
extern DBCStorage <ItemEntry> sItemStore;
|
||||
//extern DBCStorage <ItemDisplayInfoEntry> sItemDisplayInfoStore; -- not used currently
|
||||
extern DBCStorage <ItemExtendedCostEntry> sItemExtendedCostStore;
|
||||
|
|
|
|||
|
|
@ -854,6 +854,40 @@ struct GtRegenMPPerSptEntry
|
|||
float ratio;
|
||||
};
|
||||
|
||||
/* no used
|
||||
struct HolidayDescriptionsEntry
|
||||
{
|
||||
uint32 ID; // 0, this is NOT holiday id
|
||||
//char* name[16] // 1-16 m_name_lang
|
||||
// 17 name flags
|
||||
};
|
||||
*/
|
||||
|
||||
/* no used
|
||||
struct HolidayNamesEntry
|
||||
{
|
||||
uint32 ID; // 0, this is NOT holiday id
|
||||
//char* name[16] // 1-16 m_name_lang
|
||||
// 17 name flags
|
||||
};
|
||||
*/
|
||||
|
||||
struct HolidaysEntry
|
||||
{
|
||||
uint32 ID; // 0, holiday id
|
||||
//uint32 unk1; // 1
|
||||
//uint32 unk2; // 2
|
||||
//uint32 unk3[8] // 3-10, empty fields
|
||||
//uint32 unk11[13] // 11-23, some unknown data (bit strings?)
|
||||
//uint32 unk11[13] // 24-36, some empty fields (continue prev?)
|
||||
//uint32 unk11[12] // 37-48, counters?
|
||||
//uint32 holidayNameId; // 49, id for HolidayNames.dbc
|
||||
//uint32 holidayDescriptionId; // 50, id for HolidayDescriptions.dbc
|
||||
//uint32 unk51; // 51
|
||||
//uint32 unk52; // 52
|
||||
//uint32 unk53; // 53
|
||||
};
|
||||
|
||||
struct ItemEntry
|
||||
{
|
||||
uint32 ID; // 0
|
||||
|
|
|
|||
|
|
@ -53,6 +53,7 @@ const char GtOCTRegenHPfmt[]="f";
|
|||
//const char GtOCTRegenMPfmt[]="f";
|
||||
const char GtRegenHPPerSptfmt[]="f";
|
||||
const char GtRegenMPPerSptfmt[]="f";
|
||||
const char Holidaysfmt[]="nxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx";
|
||||
const char Itemfmt[]="nixiiiii";
|
||||
//const char ItemDisplayTemplateEntryfmt[]="nxxxxxxxxxxixxxxxxxxxxx";
|
||||
//const char ItemCondExtCostsEntryfmt[]="xiii";
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "7392"
|
||||
#define REVISION_NR "7393"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue