brand new lua(not working in game need help) menu

Shout-Out

User Tag List

Results 1 to 3 of 3
  1. #1
    Flake0207's Avatar Active Member
    Reputation
    30
    Join Date
    Apr 2008
    Posts
    221
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    brand new lua(not working in game need help)

    Code:
    function Archavon_summon(pUnit, Event)
        
        x = pUnit:GetX();
        y = pUnit:GetY();
        z = pUnit:GetZ();
        o = pUnit:GetO();
        
        pUnit:SpawnCreature(32353, x, y, z, o,45000);
    end
    
    
    function Boss_OnCombat(pUnit, event)
    pUnit:FullCastSpellOnTarget(58695,pUnit:GetMainTank()
    pUnit:SendChatMessage(14,0,"Your not prepared!(luaMade by jake)")
    pUnit:RegisterEvent("archavon_GetHPAndThenCastSpell",1000,0)
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 80 then
    pUnit:FullCastSpellOnTarget(58963,pUnit:GetClosestPlayer()
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 75 then
    pUnit:FullCastSpellOnTarget(58663,pUnit:GetClosestPlayer()
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 70 then
    pUnit:SendChatMessage(14,0,"You cannot kill me(luaMade by jake)")
    pUnit:FullCastSpellOnTarget(58666,pUnit:Getmaintank()
    end
    
    function Archavon_summon(pUnit, Event)
        
        x = pUnit:GetX();
        y = pUnit:GetY();
        z = pUnit:GetZ();
        o = pUnit:GetO();
        if pUnit:GetHealthPct < 62 then    
        pUnit:SpawnCreature(32353, x, y, z, o,45000);
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 58 then
    pUnit:SendChatMessage(14,0,"Minion Get them!(luaMade by jake)")
    pUnit:FullCastSpellOnTarget(58695,pUnit:GetClosestPlayer()
    end
    
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 55 then
    pUnit:SendChatMessage(14,0,"You cannot kill me(luaMade by jake)")
    pUnit:FullCastSpellOnTarget(58666,pUnit:Getmaintank()
    end
    
    
    
    
    
    
    
    
    
    function Archavon_summon(pUnit, Event)
        
        x = pUnit:GetX();
        y = pUnit:GetY();
        z = pUnit:GetZ();
        o = pUnit:GetO();
    
    
    
        if pUnit:GetHealthPct < 45 then  
        pUnit:SpawnCreature(32353, x, y, z, o,45000);
    end
    
    
    function Boss_OnCombat(pUnit, event)
    pUnit:FullCastSpellOnTarget(58695,pUnit:GetMainTank()
    if pUnit:GetHealthPct < 35 then
    pUnit:SendChatMessage(14,0,"Gettin Weak(luaMade by jake)")
    pUnit:RegisterEvent("archavon_GetHPAndThenCastSpell",1000,0)
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    
    pUnit:FullCastSpellOnTarget(58965,pUnit:GetClosestPlayer()
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 29 then
    pUnit:FullCastSpellOnTarget(58666,pUnit:GetClosestPlayer()
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 25 then
    pUnit:SendChatMessage(14,0,"You cannot kill me(luaMade by jake)")
    pUnit:FullCastSpellOnTarget(58963,pUnit:Getmaintank()
    end
    
    function Archavon_summon(pUnit, Event)
        
        x = pUnit:GetX();
        y = pUnit:GetY();
        z = pUnit:GetZ();
        o = pUnit:GetO();
        if pUnit:GetHealthPct < 20 then  
    pUnit:SendChatMessage(14,0,"Minion Get them!(luaMade by jake)")  
        pUnit:SpawnCreature(32353, x, y, z, o,45000);
    end
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    pUnit:FullCastSpellOnTarget(58695,pUnit:GetClosestPlayer()
    end
    
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    if pUnit:GetHealthPct < 20 then
    pUnit:SendChatMessage(14,0,"You cannot kill me(luaMade by jake)")
    pUnit:FullCastSpellOnTarget(58666,pUnit:Getmaintank()
    end
    
    
    function Boss_GetHPAndThenCastSpell(pUnit, event)
    
    pUnit:SendChatMessage(14,0,"Im sorry i failed you Emalon(luaMade by jake)")
    pUnit:FullCastSpellOnTarget(58666,pUnit:Getmaintank()
    end
    
    RegisterUnitEvent(31125,"Boss_OnCombat") 
    RegisterUnitEvent(31125,When, "Archavon_event")
    and the flag of the npc ive tried 2 and 7
    Last edited by Flake0207; 06-23-2009 at 04:54 PM.




    brand new lua(not working in game need help)
  2. #2
    Vision1000's Avatar Member
    Reputation
    104
    Join Date
    Jun 2008
    Posts
    122
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Edit: I think i figured out what your trying to do...

    Try this;
    Code:
    function Boss_OnCombat(pUnit, Event)
    	pUnit:SendChatMessage(14, 0, "Your not prepared!")
    	pUnit:RegisterEvent("Archavon_Summon", 100, 1)
    	pUnit:RegisterEvent("Boss_PhaseOne", 1000, 1)
    	pUnit:FullCastSpellOnTarget(58695, pUnit:GetMainTank())
    	
    end
    
    function Boss_PhaseOne(pUnit, Event)
    
    	if pUnit:GetHealthPct() < 80 then
    		pUnit:RegisterEvent("Boss_PhaseTwo", 100, 1)
    		pUnit:FullCastSpellOnTarget(58963, pUnit:GetClosestPlayer())
    	else
    		pUnit:RegisterEvent("Boss_PhaseOne", 1000, 1)
    	end
    end
    
    function Boss_PhaseTwo(pUnit, Event)
    	if pUnit:GetHealthPct() < 75 then
    		pUnit:RegisterEvent("Boss_PhaseThree", 100, 1)
    		pUnit:FullCastSpellOnTarget(58663,pUnit:GetClosestPlayer())
    	else
    		pUnit:RegisterEvent("Boss_PhaseTwo", 1000, 1)
    	end
    end
    
    function Boss_PhaseThree(pUnit, Event)
    	if pUnit:GetHealthPct() < 70 then
    		pUnit:RegisterEvent("Boss_PhaseFour", 100, 1)
    		pUnit:SendChatMessage(14,0,"You cannot kill me")
    		pUnit:FullCastSpellOnTarget(58666,pUnit:Getmaintank())
    	else
    		pUnit:RegisterEvent("Boss_PhaseThree", 1000, 1)
    	end
    end
    
    function Boss_PhaseFour(pUnit, Event)
    	if pUnit:GetHealthPct() < 62 then
    		pUnit:RegisterEvent("Boss_PhaseFive", 100, 1)
    		pUnit:RegisterEvent("Archavon_Summon", 100, 1)
    		pUnit:SendChatMessage(14,0,"Minion Get them!")
    	else
    		pUnit:RegisterEvent("Boss_PhaseFour", 1000, 1)
    	end
    end
    
    function Boss_PhaseFive(pUnit, Event)
    	if pUnit:GetHealthPct() < 58 then
    		pUnit:RegisterEvent("Boss_PhaseSix", 100, 1)
    		pUnit:FullCastSpellOnTarget(58695,pUnit:GetClosestPlayer())
    	else
    		pUnit:RegisterEvent("Boss_PhaseFive", 1000, 1)
    	end
    end
    
    function Boss_PhaseSix(pUnit, Event)
    	if pUnit:GetHealthPct() < 55 then
    		pUnit:RegisterEvent("Boss_PhaseSeven", 100, 1)
    		pUnit:SendChatMessage(14,0,"You cannot kill me")
    		pUnit:FullCastSpellOnTarget(58666,pUnit:Getmaintank())
    	else
    		pUnit:RegisterEvent("Boss_PhaseSix", 1000, 1)
    	end
    end
    
    function Boss_PhaseSeven(pUnit, Event)
    	pUnit:FullCastSpellOnTarget(58666, pUnit:GetMainTank())
    
    	if pUnit:GetHealthPct() < 45 then
    		pUnit:RegisterEvent("Boss_PhaseEight", 100, 1)
    		pUnit:RegisterEvent("Archavon_Summon", 100, 1)
    		pUnit:SendChatMessage(14, 0, "Minion Get them!")
    		pUnit:FullCastSpellOnTarget(58695,pUnit:GetMainTank())
    	else
    		pUnit:RegisterEvent("Boss_PhaseSeven", 1000, 1)
    	end
    end
    
    function Boss_PhaseEight(pUnit, Event)
    	pUnit:FullCastSpellOnTarget(58695, pUnit:GetClosestPlayer())
    
    	if pUnit:GetHealthPct() < 35 then
    		pUnit:RegisterEvent("Boss_PhaseNine", 100, 1)
    		pUnit:SendChatMessage(14,0,"Getting weak...")
    	else
    		pUnit:RegisterEvent("Boss_PhaseEight", 1000, 1)
    	end
    end
    
    function Boss_PhaseNine(pUnit, Event)
    	pUnit:FullCastSpellOnTarget(58965,pUnit:GetClosestPlayer())
    
    	if pUnit:GetHealthPct() < 29 then
    		pUnit:RegisterEvent("Boss_PhaseTen", 100, 1)
    		pUnit:FullCastSpellOnTarget(58666,pUnit:GetClosestPlayer())
    	else
    		pUnit:RegisterEvent("Boss_PhaseNine", 1000, 1)
    	end
    end
    
    function Boss_PhaseTen(pUnit, Event)
    	pUnit:FullCastSpellOnTarget(58695, pUnit:GetClosestPlayer())
    
    	if pUnit:GetHealthPct() < 25 then
    		pUnit:RegisterEvent("Boss_PhaseTen", 100, 1)
    		pUnit:SendChatMessage(14,0,"You cannot kill me!")
    		pUnit:FullCastSpellOnTarget(58963,pUnit:Getmaintank())
    	else
    		pUnit:RegisterEvent("Boss_PhaseTen", 1000, 1)
    	end
    end
    
    function Boss_PhaseEleven(pUnit, Event)
    	pUnit:FullCastSpellOnTarget(58695, pUnit:GetClosestPlayer())
    
    	if pUnit:GetHealthPct() < 20 then
    		pUnit:RegisterEvent("Boss_PhaseTwelve", 1000, 0)
    		pUnit:SendChatMessage(14,0,"Minion Get them!")
    		pUnit:RegisterEvent("Archavon_Summon", 100, 1)
    		pUnit:FullCastSpellOnTarget(58963,pUnit:Getmaintank())
    	else
    		pUnit:RegisterEvent("Boss_PhaseEleven", 1000, 1)
    	end
    end
    
    function Boss_PhaseTwelve(pUnit, Event)
    pUnit:FullCastSpellOnTarget(58965,pUnit:GetClosestPlayer())
    end
    
    function Archavon_Summon(pUnit, Event)
        x = pUnit:GetX();
        y = pUnit:GetY();
        z = pUnit:GetZ();
        o = pUnit:GetO(); 
        pUnit:SpawnCreature(32353, x, y, z, o,45000);
    end
    
    function Boss_OnDied(pUnit, Event)
    	pUnit:SendChatMessage(14,0,"Im sorry i failed you Emalon")
    end
    
    RegisterUnitEvent(31125, 4, "Boss_OnDied")
    RegisterUnitEvent(31125, 1, "Boss_OnCombat")
    The code above should work, If its doing something you don't want it to do post whats wrong back here and i'll try and fix it.
    Last edited by Vision1000; 06-23-2009 at 08:15 PM.

  3. #3
    Flake0207's Avatar Active Member
    Reputation
    30
    Join Date
    Apr 2008
    Posts
    221
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i got it to work but i think my lua egnine is messed up TY +Rep +Rep
    Last edited by Flake0207; 06-24-2009 at 04:11 PM.




Similar Threads

  1. Glitchy's MES not working so I need help with HEX editing..
    By fearkite in forum WoW ME Questions and Requests
    Replies: 0
    Last Post: 07-28-2009, 05:10 AM
  2. LUA Not Working.
    By pplzperson in forum WoW EMU Questions & Requests
    Replies: 7
    Last Post: 08-13-2008, 08:12 AM
  3. [Help] Lua not working
    By Lich King in forum World of Warcraft Emulator Servers
    Replies: 15
    Last Post: 03-15-2008, 04:41 PM
  4. Need help, not working in game
    By C-Death in forum WoW ME Questions and Requests
    Replies: 4
    Last Post: 12-31-2007, 06:28 PM
  5. New thread not working properly?
    By Linkitch in forum Suggestions
    Replies: 8
    Last Post: 01-06-2007, 12:07 AM
All times are GMT -5. The time now is 03:30 AM. 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