Correct but not working script menu

User Tag List

Results 1 to 2 of 2
  1. #1
    Laenoar's Avatar Corporal
    Reputation
    1
    Join Date
    Jul 2012
    Posts
    25
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Correct but not working script

    I stumbled across this weird problem, well not really a problem because I'm 99.99% sure I scripted everything right, well anyways, I'll show where it goes wrong.

    function GossipMenu_Send(Unit, event, player)
    Unit:GossipCreateMenu(907, player, 0)
    Unit:GossipMenuAddItem(0, "I am ready.", 1, 0)
    Unit:GossipMenuAddItem(0, "Nevermind.", 2, 0)
    Unit:GossipSendMenu(player)
    end

    function GossipMenu_Selection(Unit, event, player, id, intid, code)
    if intid == 1 then
    Unit:MoveTo(-2067.254150, 7462.796875, -18.994978, 2.029636)
    Unit:SendChatMessage(12, 0, "We better be going or else they will notice I left.")
    Unit:GossipCreateMenu(907, player, 0)
    Unit:GossipMenuAddItem(0, "It seems that we are safe, move on.", 3, 0)
    Unit:GossipSendMenu(player)
    elseif intid == 3 then
    Unit:SendChatMessage(12, 0, "Hurry!")
    Unit:MoveTo(-2133.445801, 7487.167480, -31.121170, 2.708512)
    end
    end


    if intid == 2 then
    Unit:GossipComplete()
    end

    RegisterUnitGossipEvent(5681, 1, "GossipMenu_Send")
    RegisterUnitGossipEvent(5681, 2, "GossipMenu_Selection")
    So the bold part is sort of not working, when I click the NPC and press 'I am ready.', he just walks to his given x, y, z and o. But when I press 'It seems that we are safe, move on.', the NPC only says 'Hurry!', but doesn't move to his given x, y, z and o.
    Any help, did I do anything wrong?

    EDIT:
    I fixed the problem, all I needed to add to the wrong line was this:

    elseif intid == 3 then
    Unit:SendChatMessage(12, 0, "Hurry!")
    Unit:MoveTo(-2133.445801, 7487.167480, -31.121170, 2.708512)
    Unit:StopMovement(100)
    end
    end
    Last edited by Laenoar; 07-22-2012 at 11:36 AM.

    Correct but not working script
  2. #2
    stoneharry's Avatar Moderator Harry


    Reputation
    1618
    Join Date
    Sep 2007
    Posts
    4,564
    Thanks G/R
    151/150
    Trade Feedback
    0 (0%)
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    This is because when you talk to a npc it is rooted for 30 seconds. Stopping movement for any period of time after the gossip hook has been called will overwrite this.

Similar Threads

  1. [HELP] Lua boss script not working-solutions?
    By WinKIller0 in forum World of Warcraft Emulator Servers
    Replies: 15
    Last Post: 03-21-2008, 08:19 AM
  2. [Help] Lua Script Not Working
    By Muruk in forum World of Warcraft Emulator Servers
    Replies: 26
    Last Post: 03-16-2008, 02:13 PM
  3. Simple Lua Script , not working need help!
    By Arugos in forum World of Warcraft Emulator Servers
    Replies: 16
    Last Post: 12-30-2007, 02:06 PM
  4. Not exactly a AFK Bot, but its working
    By tord13 in forum World of Warcraft General
    Replies: 11
    Last Post: 06-24-2007, 08:26 PM
  5. MWCS not working correctly, and Safe to MC?
    By Demonkunga in forum WoW ME Questions and Requests
    Replies: 1
    Last Post: 06-15-2007, 11:11 PM
All times are GMT -5. The time now is 06:43 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