very nice lua script aint working help me to fix it! menu

Shout-Out

User Tag List

Results 1 to 1 of 1
  1. #1
    TheFrostLord's Avatar Corporal
    Reputation
    1
    Join Date
    Sep 2010
    Posts
    15
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    very nice lua script aint working help me to fix it!

    hello there MMOwned i came up with idea to make class chnage script in lua. reasons:
    1) im not good with c++
    2)my repack is arcemu
    3)lua is kinda easyer for all scripters
    4)i have seen some change slass scripts but only 1 is working and its on cpp so i have decided to make my own in lua...here is the script:



    local itemid =80000
    function Remort_OnUse(item, event, player)
    if (player:IsInCombat() == true) then
    player:SendAreaTriggerMessage("U can't use this while u are in combat!")
    else
    Remort_Menu(item, player)
    end
    end

    function Remort_Menu(item, player)
    item:GossipCreateMenu(1, player, 0)
    item:GossipMenuAddItem(4, "I want to be |c00FFFF00[Rogue]! |r", 1, 0)
    item:GossipMenuAddItem(4, "I want to be |cffFF00A0[Paladin]! |r", 2, 0)
    item:GossipMenuAddItem(4, "I want to be |c0066FF00[Hunter]! |r", 3, 0)
    item:GossipMenuAddItem(4, "I want to be |c00C79C6E[Warrior]! |r", 4, 0)
    item:GossipMenuAddItem(4, "I want to be |c0000B4FF[Mage]! |r", 5, 0)
    item:GossipMenuAddItem(4, "I want to be |c00CC00FF[Warlock]! |r", 6, 0)
    item:GossipMenuAddItem(4, "I want to be |c00FF9900[Druid]! |r", 7, 0)
    item:GossipMenuAddItem(4, "I want to be |c00FFFFFF[Priest]! |r", 8, 0)
    item:GossipMenuAddItem(4, "I want to be |cff0000cc[Shaman]! |r", 9, 0)
    item:GossipMenuAddItem(4, "I want to be |c00FF0000[Death Knight]! |r", 10, 0)
    item:GossipMenuAddItem(4, "I dont want to change my class!", 11, 0)
    item:GossipMenuAddItem(0, "|cffFF00A0Script by: TheLaboureR|r", 100, 0)
    item:GossipSendMenu(player)
    end

    function Remort_OnSelect(item, event, player, id, intid, code)
    local plyr = player:GetPlayerClass()

    if (intid == 1) then
    if (plyr == 4) then
    player:SendBroadcastMessage("You are Rogue already!")
    else
    player:SetClass(4)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 2) then
    if (plyr == 2) then
    player:SendBroadcastMessage("You are Paladin already!")
    else
    player:SetClass(2)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 3) then
    if (plyr == 3) then
    player:SendBroadcastMessage("You are Hunter already!")
    else
    player:SetClass(3)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 4) then
    if (plyr == 1) then
    player:SendBroadcastMessage("You are Warrior already!")
    else
    player:SetClass(1)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 5) then
    if (plyr == then
    player:SendBroadcastMessage("You are Mage already!")
    else
    player:SetClass(
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 6) then
    if (plyr == 9) then
    player:SendBroadcastMessage("You are Warlock already!")
    else
    player:SetClass(9)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 7) then
    if (plyr == 11) then
    player:SendBroadcastMessage("You are Druid already!")
    else
    player:SetClass(11)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == then
    if (plyr == 5) then
    player:SendBroadcastMessage("You are Priest already!")
    else
    player:SetClass(5)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 9) then
    if (plyr == 7) then
    player:SendBroadcastMessage("You are Shaman already!")
    else
    player:SetClass(7)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end

    if (intid == 10) then
    if (plyr == 6) then
    player:SendBroadcastMessage("You are Death knight already!")
    else
    player:SetClass(6)
    player:SendBroadcastMessage("You may need to relog for this to take effect")
    player:GossipComplete()
    end
    end
    end

    RegisterItemGossipEvent(80000, 1, "Remort_OnUse")
    RegisterItemGossipEvent(80000, 2, "Remort_OnSelect")


    function Whelp_OnSpawn(Unit, event)
    local plyr = Unit:GetClosestPlayer()
    if (plyr ~= nil) then
    Unit:FullCastSpellOnTarget(56520, plyr)
    Unit:FullCastSpellOnTarget(56521, plyr)
    Unit:FullCastSpellOnTarget(58054, plyr)
    Unit:FullCastSpellOnTarget(48469, plyr)
    Unit:FullCastSpellOnTarget(42995, plyr)
    Unit:FullCastSpellOnTarget(48161, plyr)
    end
    end




    well the script is loaded by luahyparc with any erors but when i log ingame and try to remort (change my class) it doesnt do anything!
    please help me fast!!Thanks in advance!

    very nice lua script aint working help me to fix it!

Similar Threads

  1. Lua script doesnt work (trying to script Kurinnaxx)
    By zlo in forum WoW EMU Questions & Requests
    Replies: 6
    Last Post: 08-14-2008, 04:35 PM
  2. Noob LUA script, need some help.
    By pancakebuddy in forum World of Warcraft Emulator Servers
    Replies: 5
    Last Post: 05-14-2008, 08:33 AM
  3. [Help me] Lua script error? please help.
    By Szharz in forum World of Warcraft Emulator Servers
    Replies: 3
    Last Post: 03-22-2008, 12:20 PM
  4. [Help] Lua Script Not Working
    By Muruk in forum World of Warcraft Emulator Servers
    Replies: 26
    Last Post: 03-16-2008, 02:13 PM
  5. 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
All times are GMT -5. The time now is 08:16 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