[HELP] Lua Warp i made menu

User Tag List

Results 1 to 11 of 11
  1. #1
    knaur's Avatar Elite User
    Reputation
    400
    Join Date
    Nov 2007
    Posts
    634
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [HELP] Lua Warp i made

    Hello, im working on a Lua WarpNPC that DONT need ANY
    modifications in core or .dlls at all


    I got almost everything up to work EXEPT one thing
    No teleports to map 0 (eastern kingdom) works
    All other teleport menus works fine


    anyone that has a sollution?


    here are my lua script
    Code:
    --*****************************************************
    --*original UniversalTeleNPC script by Oxin v1.2      *
    --*modifyed to WarpNPC Script by Knaur                *
    --*http://norwegianelite.servegame.com                *
    --*Made for Norwegian Elite                           *
    --*Everyone is free to distribute and modify to their *
    --*needs but please leave the original credits        *
    --*****************************************************
    local npcid = 100000
    local menunum = 33310
    local menuicon = 4
    local teleicon = 2
    local menu =
    {
    {"[--Custom Cities & Malls--]",
    {
    {"Azshara Crater Mall", 37, 131.8699951, 995.0900269, 295.3500061},
    {"Theramore", 1, -3680.8999023, -4384.7402344, 10.5717001},
    {"Garadar City (Horde lvl 70)", 530, -1306.6899414, 7259.6801758, 33.6167984},
    {"Allerian City (Alliance lvl 70)", 530, -2918.2600098, 3980.2500000, -1.0300000},
    {"Knaur's Proffession & Trainers Mall", 169, -4155.52, -820.04, 117.78},
    {"Knaur's Armors & Weapons Mall", 169, -4176.20, -616.43, 130.46},
    {"Knaur's Materials & General Mall", 169, -4349.66, -616.71, 128.27},
    {"Knaurs Home", 0, -4858.7900391, -4379.7099609, 332.7900085}
    }
    },
    {"[--Custom Levling & Quest Areas--]",
    {
    {"Azshara Crater Lvl 20 - 70", 37, 1104.128174, 401.164734, 354.609253},
    {"Old Stranglethorn Vale Area LVL 70-74", 309, -12019.9199219, -552.8200073, 13.6000004},
    {"Loch Modan Area LVL 74-80", 0, -5364.9799805, -2940.3400879, 326.2399902}
    }
    },
    {"[--Custom lvl 70 - 80 Instances--]",
    {
    {"Stormwind Vault lvl 70", 0, -8641.5000000, 594.7500000, 95.6900024},
    {"Gnomeregan Nuclear lvl 70", 0, -5384.8100586, 311.9800110, 394.2300110},
    {"Rescue Honor Hold LVL 80 (Allie only)", 543, -1594.4399414, 1440.0000000, 59.2000008},
    {"Rescue Thrallmar LVL 80 (Horde only)", 543, -1025.5799561, 1160.6500244, 66.5500031},
    {"Old Monastery LVL 80", 44, 75.0000000, -1.0000000, 18.6700001}
    }
    },
    {"[--Event Areas--]",
    {
    {"The Norwegian Run", 0, -5076.2202148, -4754.0400391, 525.3179932},
    {"The Tower Run", 0, -11126.9003906, -1938.3499756, 93.2891006},
    {"The Demon Slayer", 0, -4738.4599609, -3315.8999023, 285.1239929},
    {"The Succy Road", 1, -8403.1796875, -38.6800003, 9.5900002},
    {"Coins Of Tangamarsh", 1, -9510.2998047, -1696.4799805, 7.9129400},
    {"Succy, The Unfinished Zone", 1, -9773.0996094, 665.1400146, 0.0000000},
    {"EasyMode's Event", 0, -5959.7094727, -49.6543884, 402.8726501},
    {"Easymode's Second Event", 0, -12966.6396484, -1323.7700195, 45.4099998},
    {"Sjonky's Event", 1, 6106.2500000, -4185.2700195, 851.4099731}
    }
    },
    {"[--Battle Arenas--]",
    {
    {"The Maul Battle Arena", 1, -3762.5100098, 1126.5600586, 131.9700012},
    {"Vitium & Allerians 1vs1 Arena", 1, 2523.65, 2575.13, 133.50},
    {"Tournament Arena", 1, 2386.05, 1966.27, 415.82},
    {"Gurubashi Arena", 0, -13249.1250000, 185.6336517, 31.6270504}
    }
    },
    {"[--Main Cities--]",
    {
    {"Orgrimmar", 1, 1502.7099609, -4415.4199219, 22.5512009},
    {"Thunder Bluff", 1, -1285.4200439, 176.5229950, 15.2031002},
    {"Silvermoon City", 530, 9414.1796875, -7278.9702148, 285.1239929},
    {"Undercity", 0, 1831.2600098, 238.5299988, 61.5200005},
    {"Darnassus", 1, 8795.7998047, 969.4270020, 31.1954994},
    {"Stormwind City", 1, -8913.2304688, 554.6329956, 94.7944031},
    {"Ironforge", 0, -4981.2500000, -881.5419922, 502.6600037},
    {"The Exodar", 530, -4014.3100586, -11896.7001953, -2.0159500},
    {"Shattrath City", 530, -1722.5799561, 5382.7001953, 2.4750400}
    }
    },
    {"[--Kalimdor Dungeons--]",
    {
    {"Blackfathom Deeps", 1, 4247.7402344, 745.8790283, -24.2966995},
    {"Dire Maul", 1, -3520.0058594, 1076.1704102, 161.1481476},
    {"Maraudon", 1, -1474.7691650, 2616.4672852, 75.9416122},
    {"Ragefire Chasm", 1, 1815.3902588, -4420.1523438, -19.0183125},
    {"Razorfen Downs", 1, -4659.2846680, -2528.1691895, 81.6837692},
    {"Razorfen Kraul", 1, -4461.4208984, -1661.4697266, 81.8943405},
    {"Wailing Caverns", 1, -742.0150146, -2217.0800781, 15.9153996},
    {"Zul'Farrak", 1, -6796.4902344, -2890.7700195, 8.8806295}
    }
    },
    {"[--Eastern Kingdom Dungeons--]",
    {
    {"Blackrock Depths", 0, -7179.4160156, -925.1062012, 166.7929688},
    {"Blackrock Spire", 0, -7524.0996094, -1230.6755371, 285.7362366},
    {"Scarlet Monastery", 0, 2871.4985352, -760.2868042, 160.3318939},
    {"Scholomance", 0, 1265.4028320, -2558.0378418, 94.1262817},
    {"Shadowfang Keep", 0, -232.5447845, 1569.0053711, 76.8921585},
    {"Stratholme", 0, 3236.8146973, -4053.5295410, 108.4591064},
    {"Sunken Temple", 0, -10172.9912109, -881.5419922, -113.8941116},
    {"The Deadmines", 0, -11208.2587891, 1677.4254150, 24.4585114},
    {"The Stockade", 0, -8764.9638672, 846.1480103, 87.5168457},
    {"Uldaman", 0, -6064.4277344, -2955.1418457, 209.7703552}
    }
    },
    {"[--Outland Dungeons--]",
    {
    {"Auchenai Crypts", 530, -3361.9836426, 5226.9316406, -101.0479965},
    {"Mana-Tombs", 530, -3077.6821289, 4946.0463867, -101.0469971},
    {"Sethekk Halls", 530, -3362.1303711, 4659.0283203, -101.0482712},
    {"Shadow Labyrinth", 530, -3645.9885254, 4942.7983398, -101.0478058},
    {"Old Hillsbrad Foothills", 530, -8335.1992188, -4056.1186523, -207.7758636},
    {"The Slave Pens", 530, 735.5180054, 7013.5625000, -72.4552078},
    {"The Steamvault", 530, 818.2276001, 6945.2768555, -80.6331406},
    {"The Underbog", 530, 781.2711792, 6750.9809570, -72.5364838},
    {"Hellfire Ramparts", 530, -362.8150024, 3077.2546387, -15.0179815},
    {"The Blood Furnace", 530, -303.5060120, 3164.8200684, 31.7425003},
    {"The Shattered Halls", 530, -310.4020081, 3082.4699707, -3.7310801},
    {"The Arcatraz", 530, 3312.0900879, 1331.8900146, 505.5589905},
    {"The Botanica", 530, 3413.6499023, 1483.3199463, 182.8379974},
    {"The Mechanar", 530, 2862.4099121, 1546.0899658, 252.1586914}
    }
    },
    {"[--Azeroth Raids--]",
    {
    {"Blackwing Lair", 469, -7674.4702148, -1108.3800049, 396.6499939},
    {"Karazhan", 0, -11118.5996094, -2019.1199951, 47.0773582},
    {"Molten Core", 230, 1116.7567139, -457.5708008, -102.6283646},
    {"Naxxramas", 533, 3005.9587402, -3434.6079102, 293.8815918},
    {"Onyxia's Lair", 1, -4749.9912109, -3754.0417480, 49.1607857},
    {"Ruins of Ahn'Qiraj", 1, -8418.5000000, 1505.9399414, 31.8232002},
    {"Temple of Ahn'Qiraj", 1, -8235.0468750, 1997.8889160, 130.0925140},
    {"Zul'Gurub", 0, -11916.2167969, -1222.9390869, 92.2874985}
    }
    },
    {"[--Outland Raids--]",
    {
    {"Black Temple", 530, -3654.2792969, 318.1719666, 36.2521477},
    {"Hyjal Summit", 1, -8171.2055664, -4170.0532227, -165.4385071},
    {"Serpentshrine Cavern", 530, 829.9206543, 6865.8750000, -63.7844009},
    {"Gruul's Lair", 530, 3551.8967285, 5084.9838867, 2.1004231},
    {"Magtheridon's Lair", 530, -313.0470276, 3086.7185059, -116.5223007},
    {"The Eye", 530, 3087.2133789, 1372.7655029, 184.5787201},
    {"Zul'Aman", 568, 119.1520004, 1761.1099854, 42.8081017}
    }
    },
    {"[--Eastern Kingdom Locations--]",
    {
    {"Arathi Highlands", 0, -907.8649902, -3534.2399902, 84.7878036},
    {"Badlands", 0, -6657.3500977, -2157.1000977, 265.1329956},
    {"Dun Morogh", 0, -5660.3300781, 755.2990112, 390.6050110},
    {"Duskwood", 0, -10517.0000000, -1158.3900146, 40.0541992},
    {"Eastern Plaguelands", 0, 3130.1699219, -3401.7600098, 140.4779968},
    {"Elwynn Forest", 0, -9465.5800781, 16.8472004, 66.9209976},
    {"Eversong Woods", 530, 8738.6796875, -6676.3300781, 70.3550034},
    {"Ghostlands", 530, 7880.0000000, -6193.0000000, 22.0000000},
    {"Hillsbrad Foothills", 0, -852.8540039, -576.7119751, 21.0293007},
    {"Loch Modan", 0, -4939.1000977, -3423.7399902, 306.5950012},
    {"Redrige Mountains", 0, -9219.3701172, -2149.9399414, 71.6060028},
    {"Silverpine Forest", 0, 511.5360107, 1638.6300049, 121.4169998},
    {"Stranglethorn Vale", 0, -12352.7998047, 211.4519958, 5.5846000},
    {"Swamp of Sorrows", 0, -10487.2998047, -3256.8701172, 40.8964005},
    {"The Hinterlands", 0, 327.8139954, -1959.9899902, 198.7239990},
    {"The Sunwell", 530, 12786.907, -6971.300, 15.427},
    {"Tirisfal Glades", 0, 2255.5000000, 288.5109863, 35.1138000},
    {"Westfall", 0, -10645.9003906, 1179.0600586, 49.1781006},
    {"Wetlands", 0, -4086.3601074, -2610.9499512, 47.0143013}
    }
    },
    {"[--Kalimdor Locations--]",
    {
    {"Ashenvale", 1, 3469.4299316, 847.6199951, 6.3647599},
    {"Azuremyst Isle", 530, -4020.4799805, -13783.2998047, 74.9001007},
    {"Bloodmyst Isle", 530, -2721.6799316, -12208.9003906, 10.0881996},
    {"Darkshore", 1, 6207.5000000, -152.8329926, 80.8184967},
    {"Desolace", 1, -93.1613998, 1691.1500244, 18.1042995},
    {"Dustwallow Marsh", 1, -3463.2600098, -4123.1298828, 21.0293007},
    {"Feralas", 1, -4458.9301758, 243.4149933, 65.6136017},
    {"Silithus", 1, -6824.1499023, 8212.7304688, 50.6674995},
    {"Stonetalon Mountains", 1, 1145.0000000, 85.6640015, 812.1430054},
    {"Tanaris", 1, -7373.6899414, -2950.1999512, 11.7598000},
    {"Teldrassil", 1, 10708.7998047, 762.0919800, 1322.3699951},
    {"The Barrens", 1, -943.9349976, -3715.4899902, 12.8385000},
    {"Winterspring", 1, 6107.6201172, -4181.6000977, 853.3220215},
    {"Tirisfal Glades", 1, 2255.5000000, 288.5109863, 35.1138000}
    }
    },
    {"[--Outland Locations--]",
    {
    {"Blade's Edge Mountains", 530, 114.0000000, 7091.0000000, 124.0000000},
    {"Hellfire Peninsula", 530, -247.4510040, 940.8980103, 85.3784027},
    {"Nagrand", 530, -526.0000000, 8440.0000000, 48.0000000},
    {"Netherstorm", 530, 2280.6799316, 2520.7500000, 116.2779999},
    {"Shadowmoon Valley", 530, -2848.0000000, 3190.0000000, 97.0000000},
    {"Terokkar Forest", 530, -1177.0000000, 5336.0000000, 31.0000000},
    {"Zangarmarsh", 530, 30.4181004, 6983.4799805, 149.6809998}
    }
    },
    }
    
    function TeleNPC_MainMenu(Unit, Player)
    local i = 0
    Unit:GossipCreateMenu(menunum, Player, 0)
    for k,v in pairs(menu) do
    i = i + 1
    if type(v[2]) == "table" then
    Unit:GossipMenuAddItem(menuicon, v[1], i, 0)
    i = i + #(v[2])
    else
    Unit:GossipMenuAddItem(teleicon, v[1], i, 0)
    end
    end
    Unit:GossipSendMenu(Player)
    end
    
    function TeleNPC_SubMenu(Unit, Player, i, Submenu)
    Unit:GossipCreateMenu(menunum-i, Player, 0)
    Unit:GossipMenuAddItem(7, "<--Back", 0, 0)
    for k,v in pairs(Submenu) do
    i = i + 1
    Unit:GossipMenuAddItem(teleicon, v[1], i, 0)
    end
    Unit:GossipSendMenu(Player)
    end
    
    function TeleNPC_OnGossipTalk(Unit, Event, Player)
    TeleNPC_MainMenu(Unit, Player)
    end
    
    function TeleNPC_OnGossipSelect(Unit, Event, Player, MenuId, Id, Code)
    local i = 0
    if(Id == 0) then
    TeleNPC_MainMenu(Unit,Player)
    else
    for k,v in pairs(menu) do
    i = i + 1
    if (Id == i) then
    if type(v[2]) == "table" then
    TeleNPC_SubMenu(Unit, Player, i, v[2])
    else
    if Player:IsInCombat() then
    Unit:SendChatMessage(12, 0, "You can't teleport while in combat!")
    else
    Player:Teleport(v[2], v[3], v[4], v[5])
    end
    Unit:GossipComplete(Player)
    end
    return
    elseif (type(v[2]) == "table") then
    for j,w in pairs(v[2]) do
    i = i + 1
    if (Id == i) then
    if Player:IsInCombat() then
    Unit:SendChatMessage(12, 0, "You can't teleport while in combat!")
    else
    Player:Teleport(w[2], w[3], w[4], w[5])
    end
    Unit:GossipComplete(Player)
    return
    end
    end
    end
    end
    end
    end
    
    RegisterUnitGossipEvent(npcid, 1, "TeleNPC_OnGossipTalk")
    RegisterUnitGossipEvent(npcid, 2, "TeleNPC_OnGossipSelect")

    And another thing, i cant get lua portals to work anymore in new arcemu


    here is the script im using:

    Code:
    function Proff_Mall (pUnit, Event)
        pUnit:Teleport (169, -4155.52, -820.04, 117.78)
    end
    RegisterGameObjectEvent (3000001, 2, "Proff_Mall")
    Last edited by knaur; 07-23-2008 at 11:07 AM.
    ------------------------------------------------------
    Knaur - Founder of The Norwegian Elite Team

    [HELP] Lua Warp i made
  2. #2
    runiker's Avatar Contributor
    Reputation
    105
    Join Date
    Nov 2007
    Posts
    501
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Try making it into 00 instead of just 0

    just an idea

    also do you know if the c++ portals work?
    if so jsut switch over to C++

  3. #3
    knaur's Avatar Elite User
    Reputation
    400
    Join Date
    Nov 2007
    Posts
    634
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by runiker View Post
    Try making it into 00 instead of just 0

    just an idea

    also do you know if the c++ portals work?
    if so jsut switch over to C++

    hmm, shall try that 00 sollution.


    well, the idea is to try walk around c++
    to make portals that aint core limited

    like this warpnpc im working on.
    ------------------------------------------------------
    Knaur - Founder of The Norwegian Elite Team

  4. #4
    runiker's Avatar Contributor
    Reputation
    105
    Join Date
    Nov 2007
    Posts
    501
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by knaur View Post
    hmm, shall try that 00 sollution.


    well, the idea is to try walk around c++
    to make portals that aint core limited

    like this warpnpc im working on.

    Yes but if you noticed blizz is trying to get tighter on
    stuff the last few patchs and i am afraid we Might
    have no other option but then C++

    [p.s. i only ment for portals atm tho]

  5. #5
    knaur's Avatar Elite User
    Reputation
    400
    Join Date
    Nov 2007
    Posts
    634
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hmm, i may have found a working one,
    but have to wait a bit to test, my players gets so pizzed of if i restarts
    all the time to test hehe

    This may work.
    Code:
    function Proffmall_onUse (pUnit, Event, pMisc)
    pMisc:Teleport (169, -4155.52, -820.04, 117.78)
    end
    RegisterGameObjectEvent (3000001, 2, 'Proffmall_onUse')
    Last edited by knaur; 07-23-2008 at 03:26 PM.
    ------------------------------------------------------
    Knaur - Founder of The Norwegian Elite Team

  6. #6
    runiker's Avatar Contributor
    Reputation
    105
    Join Date
    Nov 2007
    Posts
    501
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Well good luck and post back if it dont work

    [note i was half awake didnt notice the lua change untill you brought it up lol]

  7. #7
    knaur's Avatar Elite User
    Reputation
    400
    Join Date
    Nov 2007
    Posts
    634
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    the 00 idea you had as mapid in lua warp failed, lua didnt load.

    damn almost everything is working
    on this clean lua warp without c++ addons,
    exept i cannot teleport any locations at eastern kingdom map 0 (((

    if we find the sollution, this will be the first lua warpnpc
    that works on all cores without modifications
    Last edited by knaur; 07-24-2008 at 08:46 AM.
    ------------------------------------------------------
    Knaur - Founder of The Norwegian Elite Team

  8. #8
    WoW Havok's Avatar Member
    Reputation
    1
    Join Date
    Jul 2008
    Posts
    3
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    0 wont work in lua sorry for the bad news

  9. #9
    Power of Illuminati's Avatar Contributor
    Reputation
    179
    Join Date
    May 2008
    Posts
    1,410
    Thanks G/R
    6/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    What if you make a local variable that stands for 0, and use that? Would that work?

  10. #10
    WoW Havok's Avatar Member
    Reputation
    1
    Join Date
    Jul 2008
    Posts
    3
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Nop that wont work I tried that before myself. There is no way to get zone 0 to work in lua.

  11. #11
    knaur's Avatar Elite User
    Reputation
    400
    Join Date
    Nov 2007
    Posts
    634
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    WoW Havok: hmm damn :/
    why do "0" in mapcords work for portal scripts?
    its almost same :/


    Pwer Of Illuminati: hmm, im still a bit on learning stage when it
    comes to lua so im not so good in all codes to test im afraid

    well, if anyone in future find a way around it, feel free to
    modify the script =) would have been fun to actually get
    a warp npc to work without needing c++ mods on core updates =)
    ------------------------------------------------------
    Knaur - Founder of The Norwegian Elite Team

Similar Threads

  1. Needs Help with Warp Npc Lua
    By Lytle69 in forum WoW EMU Questions & Requests
    Replies: 3
    Last Post: 10-03-2008, 02:39 AM
  2. (Help) C++ Warp Npc
    By saro10 in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 02-09-2008, 12:06 PM
  3. help .lua portal
    By Tom_2001 in forum World of Warcraft Emulator Servers
    Replies: 12
    Last Post: 01-26-2008, 11:14 AM
  4. help .lua portal help
    By Tom_2001 in forum World of Warcraft Emulator Servers
    Replies: 7
    Last Post: 01-24-2008, 03:21 PM
  5. [HELP] Lua DLL Error
    By Rouslan in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 01-12-2008, 02:02 PM
All times are GMT -5. The time now is 11:39 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search