Core/Guilds: guild code was completely refactored and rewritten.

* OOP desing and implementation;
* all the queries are moved to prepared statements;
* guild loading is optimized;
* all the possible interaction with guild's data is done inside the guild class;
* added more hooks to GuildScript class;

WARNING: Make sure you backup your characters database before applying this change (just in case).

Known problems with guilds:
* when new member is added to the guild, MOTD is not displayed for him in guild tab of social window;
* if you add item with random property to guild bank visual representation of item below it becomes wrong (it displays wrong stack number);
* packets order differs from official: currently guild bank packet traffic is twice as more than on offy.

--HG--
branch : trunk
This commit is contained in:
azazel
2010-10-17 19:54:13 +06:00
parent f5911917b4
commit c0faed2251
27 changed files with 3892 additions and 3538 deletions
+8 -2
View File
@@ -129,6 +129,14 @@ enum ChatRestrictionType
ERR_YELL_RESTRICTED = 3
};
enum CharterTypes
{
GUILD_CHARTER_TYPE = 9,
ARENA_TEAM_CHARTER_2v2_TYPE = 2,
ARENA_TEAM_CHARTER_3v3_TYPE = 3,
ARENA_TEAM_CHARTER_5v5_TYPE = 5
};
/// Player session in the World
class WorldSession
{
@@ -272,11 +280,9 @@ class WorldSession
void SendDiscoverNewTaxiNode(uint32 nodeid);
// Guild/Arena Team
void SendGuildCommandResult(uint32 typecmd, const std::string& str, uint32 cmdresult);
void SendArenaTeamCommandResult(uint32 team_action, const std::string& team, const std::string& player, uint32 error_id);
void SendNotInArenaTeamPacket(uint8 type);
void SendPetitionShowList(uint64 guid);
void SendSaveGuildEmblem(uint32 msg);
void BuildPartyMemberStatsChangedPacket(Player *player, WorldPacket *data);