Core/Gossip: Gossip menu items will now have constant index, allowing to properly define scripts relying on that index when mixed with conditions. Script-created menus via ADD_GOSSIP_ITEM will still have the index generated dynamically

This commit is contained in:
Shauren
2011-05-26 23:57:17 +02:00
parent f91136b949
commit 0ad14aeafd
16 changed files with 587 additions and 653 deletions
+3 -3
View File
@@ -1315,7 +1315,7 @@ public:
if (!pPlayer->HasEnoughMoney(10000000))
{
pPlayer->SendBuyError(BUY_ERR_NOT_ENOUGHT_MONEY, 0, 0, 0);
pPlayer->PlayerTalkClass->CloseGossip();
pPlayer->PlayerTalkClass->SendCloseGossip();
break;
}
else
@@ -1328,7 +1328,7 @@ public:
pPlayer->CastSpell(pPlayer, 63624, true, NULL, NULL, pPlayer->GetGUID());
// Should show another Gossip text with "Congratulations..."
pPlayer->PlayerTalkClass->CloseGossip();
pPlayer->PlayerTalkClass->SendCloseGossip();
}
}
break;
@@ -2598,7 +2598,7 @@ public:
pPlayer->SetFlag(PLAYER_FLAGS, PLAYER_FLAGS_NO_XP_GAIN);
}
}
pPlayer->PlayerTalkClass->CloseGossip();
pPlayer->PlayerTalkClass->SendCloseGossip();
return true;
}
};