PDA

View Full Version : [SOLVED] Script ADD_GOSSIP_ITEM/SEND_GOSSIP_MENU?



Tyros
09-01-2016, 07:46 PM
It seems these functions have been completely removed, moved, or renamed. How should I change my script now in order to accommodate these changes?

error C2039: 'ADD_GOSSIP_ITEM': is not a member of 'Player'

Thank you

Occurs with:
player->ADD_GOSSIP_ITEM
player->ADD_GOSSIP_ITEM_EXTENDED
player->SEND_GOSSIP_MENU

Tyros
09-01-2016, 08:18 PM
Solved:

Function is no longer
player->ADD_GOSSIP_ITEM(...)
player->ADD_GOSSIP_ITEM_EXTENDED(...)They have both been merged into this
// Using provided text, not from DB
AddGossipItemFor(Player* player, uint32 icon, std::string const& text, uint32 sender, uint32 action);
// Using provided texts, not from DB
AddGossipItemFor(Player* player, uint32 icon, std::string const& text, uint32 sender, uint32 action, std::string const& popupText, uint32 popupMoney, bool coded);And now has an option for DB usage instead with
// Uses gossip item info from DB
AddGossipItemFor(Player* player, uint32 gossipMenuID, uint32 gossipMenuItemID, uint32 sender, uint32 action);And
player->SEND_GOSSIP_MENU(...)Has become
SendGossipMenuFor(Player* player, uint32 npcTextID, ObjectGuid const& guid);
SendGossipMenuFor(Player* player, uint32 npcTextID, Creature const* creature);