Пример #1
0
        void GossipSelectOption(Object* pObject, Player* plr, uint32 Id, uint32 IntId, const char* Code)
        {
            if(!pObject->IsCreature())
                return;
            Creature* pCreature = static_cast<Creature*>(pObject);

            GossipMenu* Menu;
            switch(IntId)
            {
                case 0: // Return to start
                    GossipHello(pCreature, plr);
                    break;

                case 1: //Horde
                    {
                        objmgr.CreateGossipMenuForPlayer(&Menu, pObject->GetGUID(), 4715, plr);
                        Menu->SendTo(plr);

                        QuestLogEntry* qle = plr->GetQuestLogForEntry(6002);
                        if(qle == NULL)
                            return;

                        if(qle->CanBeFinished())
                            return;

                        qle->Complete();
                        qle->SendQuestComplete();
                        qle->UpdatePlayerFields();

                        pCreature->Emote(EMOTE_ONESHOT_WAVE);
                        pCreature->Despawn(240000, 0);
                    }
                    break;

                case 2: //Ally
                    {
                        objmgr.CreateGossipMenuForPlayer(&Menu, pObject->GetGUID(), 4715, plr);
                        Menu->SendTo(plr);

                        QuestLogEntry* qle = plr->GetQuestLogForEntry(6001);
                        if(qle == NULL)
                            return;

                        if(qle->CanBeFinished())
                            return;

                        qle->Complete();
                        qle->SendQuestComplete();
                        qle->UpdatePlayerFields();

                        pCreature->Emote(EMOTE_ONESHOT_WAVE);
                        pCreature->Despawn(240000, 0);
                    }
                    break;

            }
        }
Пример #2
0
        void OnSelectOption(Object* pObject, Player* Plr, uint32 Id, const char* Code)
        {
            switch(Id)
            {
                case 0:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2714, Plr, 1, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_0); break;
                case 1:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2715, Plr, 2, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_1); break;
                case 2:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2716, Plr, 3, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_2); break;
                case 3:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2717, Plr, 4, Arcemu::Gossip::ICON_CHAT, RaggedJphn_GOSSIP_3); break;
                case 4:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2718, Plr, 5, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_4); break;
                case 5:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2719, Plr, 6, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_5); break;
                case 6:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2720, Plr, 7, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_6); break;
                case 7:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2721, Plr, 8, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_7); break;
                case 8:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2722, Plr, 9, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_8); break;
                case 9:  Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2723, Plr, 10, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_9); break;
                case 10: Arcemu::Gossip::Menu::SendQuickMenu(Plr->GetGUID(), 2725, Plr, 11, Arcemu::Gossip::ICON_CHAT, RaggedJohn_GOSSIP_10); break;
                case 11:
                {
                    QuestLogEntry* pQuest = Plr->GetQuestLogForEntry(4224);
                    if(!pQuest)
                        return;

                    pQuest->Complete();
                    pQuest->SendQuestComplete();
                    pQuest->UpdatePlayerFields();
                    Arcemu::Gossip::Menu::Complete(Plr);
                }
            }
        }
Пример #3
0
 void OnSelectOption(Object* pObject, Player* plr, uint32 Id, const char* Code)
 {
     switch(Id)
     {
         case 0: Arcemu::Gossip::Menu::SendQuickMenu(pObject->GetGUID(), 3759, plr, 1, Arcemu::Gossip::ICON_CHAT, "What do you do here?"); break;
         case 1: Arcemu::Gossip::Menu::SendQuickMenu(pObject->GetGUID(), 3760, plr, 2, Arcemu::Gossip::ICON_CHAT, "I can help you"); break;
         case 2: Arcemu::Gossip::Menu::SendQuickMenu(pObject->GetGUID(), 3761, plr, 3, Arcemu::Gossip::ICON_CHAT, "What deal?"); break;
         case 3: Arcemu::Gossip::Menu::SendQuickMenu(pObject->GetGUID(), 3762, plr, 4, Arcemu::Gossip::ICON_CHAT, "Then what happened?"); break;
         case 4: Arcemu::Gossip::Menu::SendQuickMenu(pObject->GetGUID(), 3763, plr, 5, Arcemu::Gossip::ICON_CHAT, "He is not safe, i'll make sure of that."); break;
         case 5:
         {
             QuestLogEntry* pQuest = plr->GetQuestLogForEntry(5126);
             if (pQuest)
             {
                 pQuest->Complete();
                 pQuest->UpdatePlayerFields();
                 pQuest->SendQuestComplete();
             }
             plr->Gossip_Complete();
         }break;
     }
 }