mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-31 04:56:20 +00:00
Change space indentation to tabs
This commit is contained in:
+89
-100
@@ -9,11 +9,11 @@
|
||||
//#include "doors.h"
|
||||
|
||||
struct wplist {
|
||||
int index;
|
||||
int index;
|
||||
float x;
|
||||
float y;
|
||||
float z;
|
||||
int pause;
|
||||
int pause;
|
||||
float heading;
|
||||
};
|
||||
|
||||
@@ -110,7 +110,7 @@ struct MercTemplate {
|
||||
uint32 MercSubType; // From dbstr_us.txt - 330020105^23^Race: Guktan<br>Type: Healer<br>Confidence: High<br>Proficiency: Apprentice, Tier V...
|
||||
uint16 RaceID;
|
||||
uint8 ClassID;
|
||||
uint32 MercNPCID;
|
||||
uint32 MercNPCID;
|
||||
uint8 ProficiencyID;
|
||||
uint8 TierID;
|
||||
uint8 CostFormula; // To determine cost to client
|
||||
@@ -122,10 +122,10 @@ struct MercTemplate {
|
||||
};
|
||||
|
||||
struct MercInfo {
|
||||
uint32 mercid;
|
||||
uint32 mercid;
|
||||
uint8 slot;
|
||||
char merc_name[64];
|
||||
uint32 MercTemplateID;
|
||||
uint32 MercTemplateID;
|
||||
const MercTemplate* myTemplate;
|
||||
uint32 SuspendedTime;
|
||||
bool IsSuspended;
|
||||
@@ -156,7 +156,7 @@ struct MercSpellEntry {
|
||||
uint8 minlevel;
|
||||
uint8 maxlevel;
|
||||
int16 slot;
|
||||
uint16 proc_chance;
|
||||
uint16 proc_chance;
|
||||
uint32 time_cancast; // when we can cast this spell next
|
||||
};
|
||||
|
||||
@@ -172,15 +172,15 @@ struct LootTable_Struct;
|
||||
|
||||
|
||||
class ZoneDatabase : public SharedDatabase {
|
||||
typedef list<ServerLootItem_Struct*> ItemList;
|
||||
typedef list<ServerLootItem_Struct*> ItemList;
|
||||
public:
|
||||
ZoneDatabase();
|
||||
ZoneDatabase(const char* host, const char* user, const char* passwd, const char* database,uint32 port);
|
||||
virtual ~ZoneDatabase();
|
||||
|
||||
/*
|
||||
* Objects and World Containers
|
||||
*/
|
||||
* Objects and World Containers
|
||||
*/
|
||||
void LoadWorldContainer(uint32 parentid, ItemInst* container);
|
||||
void SaveWorldContainer(uint32 zone_id, uint32 parent_id, const ItemInst* container);
|
||||
void DeleteWorldContainer(uint32 parent_id,uint32 zone_id);
|
||||
@@ -190,11 +190,11 @@ public:
|
||||
Ground_Spawns* LoadGroundSpawns(uint32 zone_id, int16 version, Ground_Spawns* gs);
|
||||
|
||||
/*
|
||||
* Traders
|
||||
*/
|
||||
* Traders
|
||||
*/
|
||||
|
||||
void SaveTraderItem(uint32 char_id,uint32 itemid,uint32 uniqueid, int32 charges,uint32 itemcost,uint8 slot);
|
||||
void UpdateTraderItemCharges(int char_id, uint32 ItemInstID, int32 charges);
|
||||
void SaveTraderItem(uint32 char_id,uint32 itemid,uint32 uniqueid, int32 charges,uint32 itemcost,uint8 slot);
|
||||
void UpdateTraderItemCharges(int char_id, uint32 ItemInstID, int32 charges);
|
||||
void UpdateTraderItemPrice(int CharID, uint32 ItemID, uint32 Charges, uint32 NewPrice);
|
||||
ItemInst* LoadSingleTraderItem(uint32 char_id, int uniqueid);
|
||||
void DeleteTraderItem(uint32 char_id);
|
||||
@@ -210,8 +210,8 @@ public:
|
||||
void UpdateBuyLine(uint32 CharID, uint32 BuySlot, uint32 Quantity);
|
||||
|
||||
/*
|
||||
* General Character Related Stuff
|
||||
*/
|
||||
* General Character Related Stuff
|
||||
*/
|
||||
bool SetServerFilters(char* name, ServerSideFilters_Struct *ssfs);
|
||||
uint32 GetServerFilters(char* name, ServerSideFilters_Struct *ssfs);
|
||||
bool GetAccountInfoForLogin(uint32 account_id, int16* admin = 0, char* account_name = 0,
|
||||
@@ -221,26 +221,26 @@ public:
|
||||
uint32* account_creation = 0);
|
||||
bool GetCharacterInfoForLogin_result(MYSQL_RES* result, uint32* character_id = 0, char* current_zone = 0,
|
||||
PlayerProfile_Struct* pp = 0, Inventory* inv = 0, ExtendedProfile_Struct *ext = 0, uint32* pplen = 0,
|
||||
uint32* guilddbid = 0, uint8* guildrank = 0, uint8 *class_= 0, uint8 *level = 0, bool *LFP = 0,
|
||||
uint32* guilddbid = 0, uint8* guildrank = 0, uint8 *class_= 0, uint8 *level = 0, bool *LFP = 0,
|
||||
bool *LFG = 0, uint8 *NumXTargets = 0, uint8* firstlogon = 0);
|
||||
bool GetCharacterInfoForLogin(const char* name, uint32* character_id = 0, char* current_zone = 0,
|
||||
PlayerProfile_Struct* pp = 0, Inventory* inv = 0, ExtendedProfile_Struct *ext = 0, uint32* pplen = 0,
|
||||
uint32* guilddbid = 0, uint8* guildrank = 0, uint8 *class_ = 0, uint8 *level = 0, bool *LFP = 0,
|
||||
bool *LFG = 0, uint8 *NumXTargets = 0, uint8* firstlogon = 0);
|
||||
void SaveBuffs(Client *c);
|
||||
void LoadBuffs(Client *c);
|
||||
void LoadBuffs(Client *c);
|
||||
void LoadPetInfo(Client *c);
|
||||
void SavePetInfo(Client *c);
|
||||
void RemoveTempFactions(Client *c);
|
||||
|
||||
/*
|
||||
* Character Inventory
|
||||
*/
|
||||
* Character Inventory
|
||||
*/
|
||||
bool NoRentExpired(const char* name);
|
||||
|
||||
/*
|
||||
* Corpses
|
||||
*/
|
||||
* Corpses
|
||||
*/
|
||||
bool GetDecayTimes(npcDecayTimes_Struct* npcCorpseDecayTimes);
|
||||
uint32 CreatePlayerCorpse(uint32 charid, const char* charname, uint32 zoneid, uint16 instanceid, uchar* data, uint32 datasize, float x, float y, float z, float heading);
|
||||
bool CreatePlayerCorpseBackup(uint32 dbid, uint32 charid, const char* charname, uint32 zoneid, uint16 instanceid, uchar* data, uint32 datasize, float x, float y, float z, float heading);
|
||||
@@ -260,15 +260,15 @@ public:
|
||||
uint32 NewGraveyardRecord(uint32 graveyard_zoneid, float graveyard_x, float graveyard_y, float graveyard_z, float graveyard_heading);
|
||||
uint32 AddGraveyardIDToZone(uint32 zone_id, uint32 graveyard_id);
|
||||
bool DeleteGraveyard(uint32 zone_id, uint32 graveyard_id);
|
||||
uint32 GetFirstCorpseID(uint32 char_id);
|
||||
uint32 GetPlayerCorpseCount(uint32 char_id);
|
||||
uint32 GetPlayerCorpseID(uint32 char_id, uint8 corpse);
|
||||
uint32 GetPlayerCorpseItemAt(uint32 corpse_id, uint16 slotid);
|
||||
uint32 GetFirstCorpseID(uint32 char_id);
|
||||
uint32 GetPlayerCorpseCount(uint32 char_id);
|
||||
uint32 GetPlayerCorpseID(uint32 char_id, uint8 corpse);
|
||||
uint32 GetPlayerCorpseItemAt(uint32 corpse_id, uint16 slotid);
|
||||
uint32 GetPlayerCorpseTimeLeft(uint8 corpse, uint8 type);
|
||||
|
||||
/*
|
||||
* Faction
|
||||
*/
|
||||
* Faction
|
||||
*/
|
||||
bool GetNPCFactionList(uint32 npcfaction_id, int32* faction_id, int32* value, uint8* temp, int32* primary_faction = 0);
|
||||
bool GetFactionData(FactionMods* fd, uint32 class_mod, uint32 race_mod, uint32 deity_mod, int32 faction_id); //rembrant, needed for factions Dec, 16 2001
|
||||
bool GetFactionName(int32 faction_id, char* name, uint32 buflen); // rembrant, needed for factions Dec, 16 2001
|
||||
@@ -279,11 +279,11 @@ public:
|
||||
bool LoadFactionValues_result(MYSQL_RES* result, faction_map & val_list);
|
||||
|
||||
/*
|
||||
* AAs
|
||||
*/
|
||||
bool LoadAAEffects();
|
||||
* AAs
|
||||
*/
|
||||
bool LoadAAEffects();
|
||||
bool LoadAAEffects2();
|
||||
bool LoadSwarmSpells();
|
||||
bool LoadSwarmSpells();
|
||||
SendAA_Struct* GetAASkillVars(uint32 skill_id);
|
||||
uint8 GetTotalAALevels(uint32 skill_id);
|
||||
uint32 GetSizeAA();
|
||||
@@ -293,8 +293,8 @@ public:
|
||||
void FillAAEffects(SendAA_Struct* aa_struct);
|
||||
|
||||
/*
|
||||
* Zone related
|
||||
*/
|
||||
* Zone related
|
||||
*/
|
||||
bool GetZoneCFG(uint32 zoneid, uint16 instance_id, NewZone_Struct *data, bool &can_bind, bool &can_combat, bool &can_levitate, bool &can_castoutdoor, bool &is_city, bool &is_hotzone, bool &allow_mercs, int &ruleset, char **map_filename);
|
||||
bool SaveZoneCFG(uint32 zoneid, uint16 instance_id, NewZone_Struct* zd);
|
||||
bool DumpZoneState();
|
||||
@@ -302,13 +302,13 @@ public:
|
||||
bool LoadStaticZonePoints(LinkedList<ZonePoint*>* zone_point_list,const char* zonename, uint32 version);
|
||||
bool UpdateZoneSafeCoords(const char* zonename, float x, float y, float z);
|
||||
uint8 GetUseCFGSafeCoords();
|
||||
int getZoneShutDownDelay(uint32 zoneID, uint32 version);
|
||||
int getZoneShutDownDelay(uint32 zoneID, uint32 version);
|
||||
|
||||
/*
|
||||
* Spawns and Spawn Points
|
||||
*/
|
||||
* Spawns and Spawn Points
|
||||
*/
|
||||
bool LoadSpawnGroups(const char* zone_name, uint16 version, SpawnGroupList* spawn_group_list);
|
||||
bool LoadSpawnGroupsByID(int spawngroupid, SpawnGroupList* spawn_group_list);
|
||||
bool LoadSpawnGroupsByID(int spawngroupid, SpawnGroupList* spawn_group_list);
|
||||
bool PopulateZoneSpawnList(uint32 zoneid, LinkedList<Spawn2*> &spawn2_list, int16 version, uint32 repopdelay = 0);
|
||||
Spawn2* LoadSpawn2(LinkedList<Spawn2*> &spawn2_list, uint32 spawn2id, uint32 timeleft);
|
||||
bool CreateSpawn2(Client *c, uint32 spawngroup, const char* zone, float heading, float x, float y, float z, uint32 respawn, uint32 variance, uint16 condition, int16 cond_value);
|
||||
@@ -317,8 +317,8 @@ public:
|
||||
void UpdateSpawn2Status(uint32 id, uint8 new_status);
|
||||
|
||||
/*
|
||||
* Grids/Paths
|
||||
*/
|
||||
* Grids/Paths
|
||||
*/
|
||||
uint32 GetFreeGrid(uint16 zoneid);
|
||||
void DeleteGrid(Client *c, uint32 sg2, uint32 grid_num, bool grid_too,uint16 zoneid);
|
||||
void DeleteWaypoint(Client *c, uint32 grid_num, uint32 wp_num,uint16 zoneid);
|
||||
@@ -326,17 +326,17 @@ public:
|
||||
void AddWP(Client *c, uint32 gridid, uint32 wpnum, float xpos, float ypos, float zpos, uint32 pause, uint16 zoneid, float heading);
|
||||
uint32 AddWPForSpawn(Client *c, uint32 spawn2id, float xpos, float ypos, float zpos, uint32 pause, int type1, int type2, uint16 zoneid, float heading);
|
||||
void ModifyGrid(Client *c, bool remove, uint32 id, uint8 type = 0, uint8 type2 = 0,uint16 zoneid = 0);
|
||||
void ModifyWP(Client *c, uint32 grid_id, uint32 wp_num, float xpos, float ypos, float zpos, uint32 script=0,uint16 zoneid =0);
|
||||
uint8 GetGridType(uint32 grid,uint32 zoneid);
|
||||
uint8 GetGridType2(uint32 grid, uint16 zoneid);
|
||||
bool GetWaypoints(uint32 grid, uint16 zoneid, uint32 num, wplist* wp);
|
||||
void ModifyWP(Client *c, uint32 grid_id, uint32 wp_num, float xpos, float ypos, float zpos, uint32 script=0,uint16 zoneid =0);
|
||||
uint8 GetGridType(uint32 grid,uint32 zoneid);
|
||||
uint8 GetGridType2(uint32 grid, uint16 zoneid);
|
||||
bool GetWaypoints(uint32 grid, uint16 zoneid, uint32 num, wplist* wp);
|
||||
void AssignGrid(Client *client, float x, float y, uint32 id);
|
||||
int GetHighestGrid(uint32 zoneid);
|
||||
int GetHighestWaypoint(uint32 zoneid, uint32 gridid);
|
||||
|
||||
/*
|
||||
* NPCs
|
||||
*/
|
||||
* NPCs
|
||||
*/
|
||||
const NPCType* GetNPCType(uint32 id);
|
||||
uint32 NPCSpawnDB(uint8 command, const char* zone, uint32 zone_version, Client *c, NPC* spawn = 0, uint32 extra = 0); // 0 = Create 1 = Add; 2 = Update; 3 = Remove; 4 = Delete
|
||||
bool SetSpecialAttkFlag(uint8 id, const char* flag);
|
||||
@@ -349,12 +349,12 @@ public:
|
||||
DBnpcspells_Struct* GetNPCSpells(uint32 iDBSpellsID);
|
||||
|
||||
/*
|
||||
* Mercs
|
||||
*/
|
||||
* Mercs
|
||||
*/
|
||||
const NPCType* GetMercType(uint32 id, uint16 raceid, uint32 clientlevel);
|
||||
void LoadMercEquipment(Merc *merc);
|
||||
void LoadMercEquipment(Merc *merc);
|
||||
void SaveMercBuffs(Merc *merc);
|
||||
void LoadMercBuffs(Merc *merc);
|
||||
void LoadMercBuffs(Merc *merc);
|
||||
bool LoadMercInfo(Client *c);
|
||||
bool LoadCurrentMerc(Client *c);
|
||||
bool SaveMerc(Merc *merc);
|
||||
@@ -363,8 +363,8 @@ public:
|
||||
//void LoadMercsForMercMerchant(NPC *merchant);
|
||||
|
||||
/*
|
||||
* Petitions
|
||||
*/
|
||||
* Petitions
|
||||
*/
|
||||
void UpdateBug(BugStruct* bug);
|
||||
void UpdateBug(PetitionBug_Struct* bug);
|
||||
void DeletePetitionFromDB(Petition* wpet);
|
||||
@@ -374,28 +374,28 @@ public:
|
||||
|
||||
|
||||
/*
|
||||
* Merchants
|
||||
*/
|
||||
* Merchants
|
||||
*/
|
||||
void SaveMerchantTemp(uint32 npcid, uint32 slot, uint32 item, uint32 charges);
|
||||
void DeleteMerchantTemp(uint32 npcid, uint32 slot);
|
||||
|
||||
/*
|
||||
* Tradeskills
|
||||
*/
|
||||
* Tradeskills
|
||||
*/
|
||||
bool GetTradeRecipe(const ItemInst* container, uint8 c_type, uint32 some_id, uint32 char_id, DBTradeskillRecipe_Struct *spec);
|
||||
bool GetTradeRecipe(uint32 recipe_id, uint8 c_type, uint32 some_id, uint32 char_id, DBTradeskillRecipe_Struct *spec);
|
||||
uint32 GetZoneForage(uint32 ZoneID, uint8 skill); /* for foraging - BoB */
|
||||
uint32 GetZoneFishing(uint32 ZoneID, uint8 skill, uint32 &npc_id, uint8 &npc_chance);
|
||||
uint32 GetZoneForage(uint32 ZoneID, uint8 skill); /* for foraging - BoB */
|
||||
uint32 GetZoneFishing(uint32 ZoneID, uint8 skill, uint32 &npc_id, uint8 &npc_chance);
|
||||
void UpdateRecipeMadecount(uint32 recipe_id, uint32 char_id, uint32 madecount);
|
||||
|
||||
/*
|
||||
* Tribute
|
||||
*/
|
||||
* Tribute
|
||||
*/
|
||||
bool LoadTributes();
|
||||
|
||||
/*
|
||||
* Doors
|
||||
*/
|
||||
* Doors
|
||||
*/
|
||||
bool DoorIsOpen(uint8 door_id,const char* zone_name);
|
||||
void SetDoorPlace(uint8 value,uint8 door_id,const char* zone_name);
|
||||
bool LoadDoors(int32 iDoorCount, Door *into, const char *zone_name, int16 version);
|
||||
@@ -409,68 +409,68 @@ public:
|
||||
void InsertDoor(uint32 did, uint16 ddoorid, const char* ddoor_name, float dxpos, float dypos, float dzpos, float dheading, uint8 dopentype, uint16 dguildid, uint32 dlockpick, uint32 dkeyitem, uint8 ddoor_param, uint8 dinvert, int dincline, uint16 dsize);
|
||||
|
||||
/*
|
||||
* Blocked Spells
|
||||
*/
|
||||
* Blocked Spells
|
||||
*/
|
||||
|
||||
int32 GetBlockedSpellsCount(uint32 zoneid);
|
||||
bool LoadBlockedSpells(int32 blockedSpellsCount, ZoneSpellsBlocked* into, uint32 zoneid);
|
||||
|
||||
/*
|
||||
* Traps
|
||||
*/
|
||||
* Traps
|
||||
*/
|
||||
bool LoadTraps(const char* zonename, int16 version);
|
||||
char* GetTrapMessage(uint32 trap_id);
|
||||
|
||||
/*
|
||||
* Time
|
||||
*/
|
||||
* Time
|
||||
*/
|
||||
uint32 GetZoneTZ(uint32 zoneid, uint32 version);
|
||||
bool SetZoneTZ(uint32 zoneid, uint32 version, uint32 tz);
|
||||
|
||||
/*
|
||||
* Weather
|
||||
*/
|
||||
* Weather
|
||||
*/
|
||||
uint8 GetZoneWeather(uint32 zoneid, uint32 version);
|
||||
bool SetZoneWeather(uint32 zoneid, uint32 version, uint8 w);
|
||||
/*
|
||||
* Group
|
||||
*/
|
||||
* Group
|
||||
*/
|
||||
void RefreshGroupFromDB(Client *c);
|
||||
uint8 GroupCount(uint32 groupid);
|
||||
/*
|
||||
* Raid
|
||||
*/
|
||||
* Raid
|
||||
*/
|
||||
uint8 RaidGroupCount(uint32 raidid, uint32 groupid);
|
||||
|
||||
/*
|
||||
* Instancing
|
||||
*/
|
||||
* Instancing
|
||||
*/
|
||||
void ListAllInstances(Client* c, uint32 charid);
|
||||
|
||||
/*
|
||||
* QGlobals
|
||||
*/
|
||||
* QGlobals
|
||||
*/
|
||||
void QGlobalPurge();
|
||||
|
||||
/*
|
||||
* Alternate Currency
|
||||
*/
|
||||
void LoadAltCurrencyValues(uint32 char_id, std::map<uint32, uint32> ¤cy);
|
||||
void UpdateAltCurrencyValue(uint32 char_id, uint32 currency_id, uint32 value);
|
||||
/*
|
||||
* Alternate Currency
|
||||
*/
|
||||
void LoadAltCurrencyValues(uint32 char_id, std::map<uint32, uint32> ¤cy);
|
||||
void UpdateAltCurrencyValue(uint32 char_id, uint32 currency_id, uint32 value);
|
||||
|
||||
/*
|
||||
* Misc stuff.
|
||||
* PLEASE DO NOT ADD TO THIS COLLECTION OF CRAP UNLESS YOUR METHOD
|
||||
* REALLY HAS NO BETTER SECTION
|
||||
*/
|
||||
bool logevents(const char* accountname,uint32 accountid,uint8 status,const char* charname,const char* target, const char* descriptiontype, const char* description,int event_nid);
|
||||
* Misc stuff.
|
||||
* PLEASE DO NOT ADD TO THIS COLLECTION OF CRAP UNLESS YOUR METHOD
|
||||
* REALLY HAS NO BETTER SECTION
|
||||
*/
|
||||
bool logevents(const char* accountname,uint32 accountid,uint8 status,const char* charname,const char* target, const char* descriptiontype, const char* description,int event_nid);
|
||||
void GetEventLogs(const char* name,char* target,uint32 account_id=0,uint8 eventid=0,char* detail=0,char* timestamp=0, CharacterEventLog_Struct* cel=0);
|
||||
uint32 GetKarma(uint32 acct_id);
|
||||
void UpdateKarma(uint32 acct_id, uint32 amount);
|
||||
|
||||
/*
|
||||
* Things which really dont belong here...
|
||||
*/
|
||||
* Things which really dont belong here...
|
||||
*/
|
||||
int16 CommandRequirement(const char* commandname);
|
||||
|
||||
protected:
|
||||
@@ -488,14 +488,3 @@ extern ZoneDatabase database;
|
||||
|
||||
#endif /*ZONEDB_H_*/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user