Need help with this lua gossip script menu

Shout-Out

User Tag List

Results 1 to 2 of 2
  1. #1
    diviee3's Avatar Sergeant Major
    Reputation
    16
    Join Date
    Jan 2010
    Posts
    176
    Thanks G/R
    0/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Need help with this lua gossip script

    Hey guys,
    I made a simple gossip script that when you select the Enter Arena option in the gossip menu it teleports you to the arena.
    But, i want the script to first check if there is an npc entry id at a certain point or area or even is spawned, and if that npc is spawned then it teleports you. If the npc is NOT spawned, it will send a message: "I'm sorry, there are already players inside." I know its possible, i just forgot the commands and cant find em anymore. Anyone knows the "if" lua command or knows how to do it?
    Help is greatly appreciated.

    Code:
    local Teleporter_ID = 104144.
    
    function Register_OnTalk(Unit, Event, Player)
       Unit:GossipCreateMenu(100, player, 0)
       Unit:GossipMenuAddItem(0, "Enter Arena.", 1, 0)
       Unit:GossipMenuAddItem(0, "Nevermind. 2, 0)
       Unit:GossipSendMenu(player)
    end
    
    function Register_OnSelect(Unit, Event, player, id, intid, code, pMisc)
        if (intid  == 1) then
           player:SendBroadcastMessage("Have fun.")
           player:Teleport(0, -10884.901367, 1514.177002, 91.469772)
           Unit:GossipComplete()
       end
    
       if (intid == 2) then
           Unit:GossipComplete()
       end
    end
    
    RegisterUnitGossipEvent(Teleporter_ID, 1, "Register_OnTalk")
    RegisterUnitGossipEvent(Teleporter_ID, 2, "Register_OnSelect")
    EDIT: I'm using an arcemu 2.4.3 server. Hope someone can help
    Last edited by diviee3; 06-18-2010 at 09:08 PM.

    Need help with this lua gossip script
  2. #2
    diviee3's Avatar Sergeant Major
    Reputation
    16
    Join Date
    Jan 2010
    Posts
    176
    Thanks G/R
    0/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    no one knows?

Similar Threads

  1. Need help with this LUA script, please.
    By Eliteplague in forum WoW Bots Questions & Requests
    Replies: 6
    Last Post: 11-18-2011, 01:27 PM
  2. [Mangos] need help with this web script
    By eric125 in forum WoW EMU Questions & Requests
    Replies: 2
    Last Post: 07-20-2010, 10:56 PM
  3. Need help with an LUA script.
    By Ryoken in forum WoW EMU Questions & Requests
    Replies: 4
    Last Post: 06-21-2009, 09:30 PM
  4. Help with this LUA script
    By jordash in forum World of Warcraft Emulator Servers
    Replies: 7
    Last Post: 03-08-2008, 04:19 PM
All times are GMT -5. The time now is 11:55 AM. 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