Core/Guilds: Implemented guild news & guild rewards tab

Signed-off-by: Sovak <Sovak007@gmail.com>
Signed-off-by: Nay <dnpd.dd@gmail.com>
This commit is contained in:
Sovak authored and Nay committed 2012-09-09 22:43:44 +01:00
1 parent 271e9cb9e6
commit 2440a28755
13 files changed
+363 -10

No files matched your search

+6
View File
@@ -63,6 +63,8 @@
#include "GameObjectAI.h"
#include "AccountMgr.h"
#include "InstanceScript.h"
#include "Guild.h"
#include "GuildMgr.h"
pEffect SpellEffects[TOTAL_SPELL_EFFECTS]=
{
@@ -1567,6 +1569,10 @@ void Spell::DoCreateItem(uint32 /*i*/, uint32 itemtype)
// create the new item and store it
Item* pItem = player->StoreNewItem(dest, newitemid, true, Item::GenerateItemRandomPropertyId(newitemid));
if ((pProto->Quality == ITEM_QUALITY_EPIC && pProto->ItemLevel >= MinNewsItemLevel[sWorld->getIntConfig(CONFIG_EXPANSION)]) || pProto->Quality > ITEM_QUALITY_EPIC)
if (Guild* guild = sGuildMgr->GetGuildById(player->GetGuildId()))
guild->GetNewsLog().AddNewEvent(GUILD_NEWS_ITEM_CRAFTED, time(NULL), player->GetGUID(), 0, pProto->ItemId);
// was it successful? return error if not
if (!pItem)
{