(Help) C++ Warp Npc menu

User Tag List

Results 1 to 3 of 3
  1. #1
    saro10's Avatar Member
    Reputation
    3
    Join Date
    Jan 2008
    Posts
    10
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    (Help) C++ Warp Npc

    hey all ive made my own server and i have the Npc Teleporter and ive tried to make the tabs but i have failed so far.

    and i need someone to make a level road tab to the start of hyjal , one to gmisland.

    If anyone helps i will make them Admin on server if they wish.


    Thanks for whoever helps in anyway


    Saro

    (Help) C++ Warp Npc
  2. #2
    King Shaun's Avatar Member
    Reputation
    419
    Join Date
    Dec 2007
    Posts
    1,305
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Right, the best thing do to is this:

    Go the the programs section in the forums.
    Download WARPNPC CREATOR for ASCENT.
    Use that, it is simple an easy to use and it creates all the tabs for you!
    It is genious!

    Note: It does cause an error in the code, which can easily be fixed by adding a bit of text, it explains in the post.

    Hope that helps!


    Threads of the Week: [Errage] [Blizzard] [Rapidshare]

  3. #3
    Le Froid's Avatar Contributor
    Reputation
    172
    Join Date
    Mar 2007
    Posts
    1,327
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You added
    Code:
     Menu->AddItem(1, "AREA", 1);
    part?
    All you need is after setting some stuff up after that do
    Code:
    case 1:
     Plr->EventTeleport( COORDS );
    (just basic part of it)


    EDIT: Here is an AFG teleporter I found, may help
    Code:
    #include "StdAfx.h"
    #include "Setup.h"
    
    
    class SCRIPT_DECL Warper : public GossipScript
    {
    public:
        void GossipHello(Object * pObject, Player* Plr, bool AutoSend);
        void GossipSelectOption(Object * pObject, Player* Plr, uint32 Id, uint32 IntId, const char * Code);
        void GossipEnd(Object * pObject, Player* Plr);
        void Destroy()
        {
            delete this;
        }
    };
    void Warper::GossipHello(Object * pObject, Player* Plr, bool AutoSend)
        {
            GossipMenu *Menu;
            objmgr.CreateGossipMenuForPlayer(&Menu, pObject->GetGUID(), 1, Plr);
            Menu->AddItem(0, "Level 50-99 Area", 1);
            Menu->AddItem(0, "Level 100-149 Area", 2);
            Menu->AddItem(0, "Level 150-199 Area", 3);
            Menu->AddItem(0, "Level 200+ Ah'Qirraj Area", 4);
            Menu->AddItem(0, "PvP Arena", 5);
            Menu->AddItem(0, "Shopping Center", 6);
            Menu->AddItem(0, "High Level Class Trainers", 7);
            Menu->AddItem(0, "Fun Quests Zone+ Portals to All Area", 8);
            Menu->AddItem(0, "All in One Map Level 1-255+ AKA Hyjal", 9);
            Menu->AddItem(0, "Chronos Battleground", 10);
            Menu->AddItem(0, "Holy Shopping Center", 11);
            Menu->AddItem(0, "Naxxramas Entry", 12);
    
             if(AutoSend)
                Menu->SendTo(Plr);
        }
    
    void Warper::GossipSelectOption(Object * pObject, Player* Plr, uint32 Id, uint32 IntId, const char * Code)
        {
        Creature * pCreature = (pObject->GetTypeId()==TYPEID_UNIT)?((Creature*)pObject):NULL;
        if(pCreature==NULL)
            return;
    
            GossipMenu * Menu;
            switch(IntId)
            {
                
            case 1: 
                     {
                           Plr->EventTeleport(1, -627.069702, -2519.464355, 91.769150);
                         }
                         break;
                         
                     case 2:
                          {
                               Plr->EventTeleport(0, -11131.925781, -1829.380249, 71.837288);
                               }
                               break;
                          
                     case 3:
                          {
                               Plr->EventTeleport(230, 1116.369995, -458.123993, -102.811348);
                               }
                               break;
                               
                     case 4:
                          {
                               Plr->EventTeleport(509, -8452.962891, 1534.351929, 321.908716);
                               }
                               break;
                               
                     case 5:
                          {
                               Plr->EventTeleport(0, -13227.691406, 230.985336, 33.228024);
                               }
                               break;
                               
                     case 6:
                          {
                               Plr->EventTeleport(30, 20.236012, -299.914551, 14.033435);
                               }
                               break;
                               
                     case 7:
                          {
                               Plr->EventTeleport(30, 353.021484, -301.219391, -42.987324);
                               }
                               break;
                               
                     case 8:
                          {
                               Plr->EventTeleport(30, -247.062973, -261.332184, 7.645180);
                               }
                               break;
                               
                     case 9:
                          {
                               Plr->EventTeleport(1, 4631.811523, -3828.893555, 943.290466);
                               }
                               break;
                               
                     case 10:
                          {
                               Plr->EventTeleport(529, 3358, 1295.180176, 1291.109253, -12.680390);
                               }
                               break;
                               
                     case 11:
                          {
                               Plr->EventTeleport(0, -8512.835938, 861.715637, 109.843857);
                               }
                               break;
                               
                     case 12:
                          {
                               Plr->EventTeleport(0, 3103.101807, -3712.486572, 132.566681);
                               }
                               break;
    
                         
            
                 }
        }
    
    void Warper::GossipEnd(Object * pObject, Player* Plr)
    {
        GossipScript::GossipEnd(pObject, Plr);
    }
    
    void SetupWarper(ScriptMgr * mgr)
    {
        GossipScript * gs = (GossipScript*) new Warper();
        
        mgr->register_gossip_script(600000, gs);
        mgr->register_gossip_script(600001, gs);
        mgr->register_gossip_script(600002, gs);         
    }
    Last edited by Le Froid; 02-09-2008 at 12:21 PM.

Similar Threads

  1. Need Help With Warp NPC
    By Juve21 in forum World of Warcraft General
    Replies: 3
    Last Post: 10-12-2008, 10:40 PM
  2. Needs Help with Warp Npc Lua
    By Lytle69 in forum WoW EMU Questions & Requests
    Replies: 3
    Last Post: 10-03-2008, 02:39 AM
  3. Help please , warp NPC
    By Etzzhy in forum World of Warcraft Emulator Servers
    Replies: 14
    Last Post: 07-07-2008, 02:23 PM
  4. [Help]Warp Npc New
    By danis in forum World of Warcraft Emulator Servers
    Replies: 9
    Last Post: 02-12-2008, 10:10 AM
  5. [Help] Warp Npc
    By kanqaz in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 12-08-2007, 09:06 AM
All times are GMT -5. The time now is 08:17 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search