45#define GOSSIP_SENDER_LEARN 50
46#define GOSSIP_SENDER_UNLEARN 51
47#define GOSSIP_SENDER_CHECK 52
243 player->
CastSpell(player, triggeredSpellId,
true);
263 uint32 reqSpell = spellEffectInfo.TriggerSpell;
267 Item* item =
nullptr;
274 TC_LOG_DEBUG(
"scripts",
"player attempt to unlearn spell {}, but item {} is equipped.", reqSpell, item->
GetEntry());
402 player->
CastSpell(player, spellId,
true);
405 if (alternativeSpellId)
406 creature->
CastSpell(player, alternativeSpellId,
true);
645 npcTextId = altTextId;
654 bool canLearn =
false;
759 switch (gossipListId)
@ EQUIP_ERR_CLIENT_LOCKED_OUT
@ BUY_ERR_NOT_ENOUGHT_MONEY
#define TC_LOG_DEBUG(filterType__,...)
#define INVENTORY_SLOT_BAG_0
void SendGossipMenuFor(Player *player, uint32 npcTextID, ObjectGuid const &guid)
void AddGossipItemFor(Player *player, GossipOptionIcon icon, std::string const &text, uint32 sender, uint32 action)
void ClearGossipMenuFor(Player *player)
void CloseGossipMenuFor(Player *player)
ItemTemplate const * GetTemplate() const
static ObjectGuid GetGUID(Object const *o)
bool GetQuestRewardStatus(uint32 quest_id) const
bool ModifyMoney(int32 amount, bool sendError=true)
WorldSession * GetSession() const
Item * GetItemByPos(uint16 pos) const
bool HasSkill(uint32 skill) const
bool HasEnoughMoney(uint32 amount) const
uint16 GetBaseSkillValue(uint32 skill) const
void SendBuyError(BuyResult msg, Creature *creature, uint32 item, uint32 param) const
void RemoveSpell(uint32 spell_id, bool disabled=false, bool learn_low_rank=true)
void PrepareQuestMenu(ObjectGuid guid)
void SendEquipError(InventoryResult msg, Item *pItem, Item *pItem2=nullptr, uint32 itemid=0) const
ReputationRank GetReputationRank(uint32 faction_id) const
bool HasSpell(uint32 spell) const override
uint32 GetGossipTextId(uint32 menuId, WorldObject *source)
PlayerMenu * PlayerTalkClass
std::array< SpellEffectInfo, MAX_SPELL_EFFECTS > const & GetEffects() const
bool IsQuestGiver() const
SpellCastResult CastSpell(CastSpellTargetArg const &targets, uint32 spellId, CastSpellExtraArgs const &args={ })
void SendListInventory(ObjectGuid guid)
void SendTrainerList(Creature *npc)
GameObjectAI * GetAI(GameObject *go) const override
go_soothsaying_for_dummies()
CreatureAI * GetAI(Creature *creature) const override
npc_engineering_tele_trinket()
CreatureAI * GetAI(Creature *creature) const override
CreatureAI * GetAI(Creature *creature) const override
CreatureAI * GetAI(Creature *creature) const override
CreatureAI * GetAI(Creature *creature) const override
void AddSC_npc_professions()
#define GOSSIP_SENDER_CHECK
void ProfessionUnlearnSpells(Player *player, uint32 type)
#define GOSSIP_SENDER_LEARN
int32 DoHighUnlearnCost(Player *)
int32 DoMedUnlearnCost(Player *player)
bool EquippedOk(Player *player, uint32 spellId)
@ OPTION_LEARN_DRAGONSCALE
int32 DoLowUnlearnCost(Player *player)
void ProcessCastaction(Player *player, Creature *creature, uint32 spellId, uint32 triggeredSpellId, int32 cost)
#define GOSSIP_SENDER_UNLEARN
void ProcessUnlearnAction(Player *player, Creature *creature, uint32 spellId, uint32 alternativeSpellId, int32 cost)
@ SPELL_LEARN_TO_EVERLOOK
int32 DoLearnCost(Player *)
bool OnGossipSelect(Player *player, uint32 menuId, uint32 gossipListId) override
go_soothsaying_for_dummiesAI(GameObject *go)
bool OnGossipHello(Player *player) override
bool CanLearn(Player *player, uint32 textId, uint32 altTextId, uint32 skillValue, uint32 reqSpellId, uint32 spellId, uint32 &npcTextId)
npc_engineering_tele_trinketAI(Creature *creature)
bool OnGossipSelect(Player *player, uint32, uint32 gossipListId) override
void SendActionMenu(Player *player, uint32 action)
npc_prof_alchemyAI(Creature *creature)
bool OnGossipHello(Player *player) override
bool HasAlchemySpell(Player *player)
bool OnGossipSelect(Player *player, uint32, uint32 gossipListId) override
npc_prof_blacksmithAI(Creature *creature)
void SendActionMenu(Player *player, uint32 action)
bool OnGossipSelect(Player *player, uint32, uint32 gossipListId) override
bool HasWeaponSub(Player *player)
bool OnGossipHello(Player *player) override
bool OnGossipHello(Player *player) override
bool OnGossipSelect(Player *player, uint32, uint32 gossipListId) override
void SendActionMenu(Player *player, uint32 action)
npc_prof_leatherAI(Creature *creature)
npc_prof_tailorAI(Creature *creature)
void SendActionMenu(Player *player, uint32 action)
bool OnGossipHello(Player *player) override
bool HasTailorSpell(Player *player)
bool OnGossipSelect(Player *player, uint32, uint32 gossipListId) override