[Help] LUA failed to load menu

User Tag List

Results 1 to 9 of 9
  1. #1
    bolie2008's Avatar Member
    Reputation
    2
    Join Date
    Nov 2008
    Posts
    12
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [Help] LUA failed to load

    This is my first LUA I ever made and I did it in my Scripts folder and started server. Then it didn't load and I checked what it said in the arcemu-world.exe and it said this:
    Code:
    script/EpochBolie.LUA...
    Failed. (could not load)
    scripts/EpochBolie.LUA:8: ´(´ excepted near ´pUnit´
    This is the LUA i used:
    Code:
    function EpochBolie_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Our destiny has lead us to this place... and now we fight...")
    pUnit:RegisterEvent("ShadowBlast", 15000, 0)
    pUnit:RegisterEvent("Phase_1", 1000, 0)
    end
    
    function EpochBolie_OnDied
    pUnit:SendChatMessage(14, 0, "I guess everything is as... time wanted to...")
    pUnit:RemoveEvents()
    end
    
    function EpochBolie_LeaveCombat (pUnit, Event)
    pUnit:RemoveEvents()
    end
    
    function Phase_1(pUnit, Event)
    if GetHealthPct() <= 85 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I guess fate is on your side... I'm injured already... But I've seen my future and know I will win this battle!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop",21000, 0)
    pUnit:RegisterEvent("ShadowBlast",15000, 0)
    pUnit:RegisterEvent("Phase_2", 1000, 0)
    end
    end
    
    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 60 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Mhmph... I didn't know this fight would last so long...")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 19000, 0)
    pUnit:RegisterEvent("ShadowBlast", 12000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("FrostCleave", 11000, 0)
    pUnit:RegisterEvent("Phase_3, 1000, 0)
    end
    end
    
    Function Phase_3(pUnit, Event)
    if pUnit:GetHealthPct() <= 40 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I see the end of the fight is near... I may still make it if I open all my power... Behold mortals... MY TRUE POWER!!!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 17000, 0)
    pUnit:RegisterEvent("ShadowBlast", 11000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("Enrage2", 7000, 0)
    pUnit:RegisterEvent("FrostCleave", 10000, 0)
    pUnit:RegisterEvent("Summon", 1000, 1)
    end
    end
    
    function Summon(pUnit, Event)
    pUnit:RemoveEvents()
    x = pUnit:GetX()
    y = pUnit:GetY()
    z = pUnit:GetZ()
    o = pUnit:GetO()
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    end
    
    
    function FireBreath(pUnit, Event)
    pUnit:CastSpellOnTarget(49110, pUnit:GetMainTank())
    end
    
    function TimeStop(pUnit, Event)
    pUnit:CastSpell(60074)
    end
    
    function ShadowBlast(pUnit, Event)
    pUnit:CastSpellOnTarget(41078, pUnit:GetMainTank())
    end
    
    function Enrage(pUnit, Event)
    pUnit:CastSpell(26041)
    end
    
    function Enrage2(pUnit, Event)
    pUnit:CastSpell(42705)
    end
    
    function FrostCleave(pUnit, Event)
    pUnit:CastSpellOnTarget(51857, pUnit:GetMainTank())
    end
    
    
    RegisterUnitEvent(101101, 1, "BossName_OnCombat")
    RegisterUnitEvent(101101, 2, "BossName_OnLeaveCombat")
    RegisterUnitEvent(101101, 4, "BossName_OnDied")
    This is the SQL I use:

    Code:
    insert into `creature_names` (`entry`, `name`, `subname`, `info_str`, `Flags1`, `type`, `family`, `rank`, `unk4`, `spelldataid`, `male_displayid`, `female_displayid`, `male_displayid2`, `female_displayid2`, `unknown_float1`, `unknown_float2`, `civilian`, `leader`) 
    values ('101101', "Infinite Bounty Hunter", "The Infinite Brood", '', '0', '2', '0', '3', '0', '0', '19135', '0', '0', '0', '1', '1', '0', '0');
    
    insert into `creature_proto` (`entry`, `minlevel`, `maxlevel`, `faction`, `minhealth`, `maxhealth`, `mana`, `scale`, `npcflags`, `attacktime`, `attacktype`, `mindamage`, `maxdamage`, `can_ranged`, `rangedattacktime`, `rangedmindamage`, `rangedmaxdamage`, `respawntime`, `armor`, `resistance1`, `resistance2`, `resistance3`, `resistance4`, `resistance5`, `resistance6`, `combat_reach`, `bounding_radius`, `auras`, `boss`, `money`, `invisibility_type`, `death_state`, `walk_speed`, `run_speed`, `fly_speed`, `extra_a9_flags`, `spell1`, `spell2`, `spell3`, `spell4`, `spell_flags`, `modImmunities`) 
    values ('101101', '80', '80', '14', '5380000', '5380000', '829537', '1.7', '0', '2500', '0', '12500', '15500', '0', '0', '0', '0', '18001000', '1200', '0', '0', '0', '0', '0', '0', '2.2', '0', "0", '1', '5836305', '0', '2', '2.50', '8.00', '2.50', '0', '0', '0', '0', '0', '0', '0');
    
    insert into `creature_names` (`entry`, `name`, `subname`, `info_str`, `Flags1`, `type`, `family`, `rank`, `unk4`, `spelldataid`, `male_displayid`, `female_displayid`, `male_displayid2`, `female_displayid2`, `unknown_float1`, `unknown_float2`, `civilian`, `leader`) 
    values ('101102', "Infinite Dragon", "Infinite Bounty Hunter's Minion", '', '0', '2', '0', '1', '0', '0', '19135', '0', '0', '0', '1', '1', '0', '0');
    
    insert into `creature_proto` (`entry`, `minlevel`, `maxlevel`, `faction`, `minhealth`, `maxhealth`, `mana`, `scale`, `npcflags`, `attacktime`, `attacktype`, `mindamage`, `maxdamage`, `can_ranged`, `rangedattacktime`, `rangedmindamage`, `rangedmaxdamage`, `respawntime`, `armor`, `resistance1`, `resistance2`, `resistance3`, `resistance4`, `resistance5`, `resistance6`, `combat_reach`, `bounding_radius`, `auras`, `boss`, `money`, `invisibility_type`, `death_state`, `walk_speed`, `run_speed`, `fly_speed`, `extra_a9_flags`, `spell1`, `spell2`, `spell3`, `spell4`, `spell_flags`, `modImmunities`) 
    values ('101102', '80', '80', '14', '110000', '110000', '55000', '0.7', '0', '2200', '0', '3500', '5500', '0', '0', '0', '0', '0', '700', '0', '0', '0', '0', '0', '0', '0.6', '0', "0", '1', '103505', '0', '2', '2.50', '8.00', '14.00', '0', '0', '0', '0', '0', '0', '0');
    Please tell me how I can fix this.

    Thank you! :wave:

    [Help] LUA failed to load
  2. #2
    Dynashock's Avatar Contributor

    Reputation
    176
    Join Date
    Nov 2007
    Posts
    203
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You forgot to put (pUnit, event) behind 'function EpochBolie_OnDied'. I also noticed some other errors which I fixed.

    So the fixed script:
    Code:
    function EpochBolie_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Our destiny has lead us to this place... and now we fight...")
    pUnit:RegisterEvent("ShadowBlast", 15000, 0)
    pUnit:RegisterEvent("Phase_1", 1000, 0)
    end
    
    function EpochBolie_OnDied(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "I guess everything is as... time wanted to...")
    pUnit:RemoveEvents()
    end
    
    function EpochBolie_LeaveCombat(pUnit, Event)
    pUnit:RemoveEvents()
    end
    
    function Phase_1(pUnit, Event)
    if pUnit:GetHealthPct() <= 85 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I guess fate is on your side... I'm injured already... But I've seen my future and know I will win this battle!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop",21000, 0)
    pUnit:RegisterEvent("ShadowBlast",15000, 0)
    pUnit:RegisterEvent("Phase_2", 1000, 0)
    end
    end
    
    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 60 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Mhmph... I didn't know this fight would last so long...")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 19000, 0)
    pUnit:RegisterEvent("ShadowBlast", 12000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("FrostCleave", 11000, 0)
    pUnit:RegisterEvent("Phase_3, 1000, 0)
    end
    end
    
    function Phase_3(pUnit, Event)
    if pUnit:GetHealthPct() <= 40 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I see the end of the fight is near... I may still make it if I open all my power... Behold mortals... MY TRUE POWER!!!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 17000, 0)
    pUnit:RegisterEvent("ShadowBlast", 11000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("Enrage2", 7000, 0)
    pUnit:RegisterEvent("FrostCleave", 10000, 0)
    pUnit:RegisterEvent("Summon", 1000, 1)
    end
    end
    
    function Summon(pUnit, Event)
    pUnit:RemoveEvents()
    x = pUnit:GetX()
    y = pUnit:GetY()
    z = pUnit:GetZ()
    o = pUnit:GetO()
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    end
    
    
    function FireBreath(pUnit, Event)
    pUnit:CastSpellOnTarget(49110, pUnit:GetMainTank())
    end
    
    function TimeStop(pUnit, Event)
    pUnit:CastSpell(60074)
    end
    
    function ShadowBlast(pUnit, Event)
    pUnit:CastSpellOnTarget(41078, pUnit:GetMainTank())
    end
    
    function Enrage(pUnit, Event)
    pUnit:CastSpell(26041)
    end
    
    function Enrage2(pUnit, Event)
    pUnit:CastSpell(42705)
    end
    
    function FrostCleave(pUnit, Event)
    pUnit:CastSpellOnTarget(51857, pUnit:GetMainTank())
    end
    
    
    RegisterUnitEvent(101101, 1, "EpochBolie_OnCombat")
    RegisterUnitEvent(101101, 2, "EpochBolie_LeaveCombat")
    RegisterUnitEvent(101101, 4, "EpochBolie_OnDied")
    There's something which is bothering me though. In the third phase you register the summon function after 1 second, and this function removes all previous events, thus registering the other functions in the third phase makes no sense since you're removing them.

  3. #3
    bolie2008's Avatar Member
    Reputation
    2
    Join Date
    Nov 2008
    Posts
    12
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thank you soooo much Dynashock I am so newb at LUA...
    ...I need help again....

    Code:
    scripts/EpochBolie.LUA...
    failed. (could not load)
    scripts/EpochBolie.LUA:34: '=' excepted near Phase_3
    This is the LUA now as i speak:

    Code:
    function EpochBolie_OnDied(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "I guess everything is as... time wanted to...")
    pUnit:RemoveEvents()
    end
    
    function EpochBolie_LeaveCombat(pUnit, Event)
    pUnit:RemoveEvents()
    end
    
    function Phase_1(pUnit, Event)
    if GetHealthPct() <= 85 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I guess fate is on your side... I'm injured already... But I've seen my future and know I will win this battle!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop",21000, 0)
    pUnit:RegisterEvent("ShadowBlast",15000, 0)
    pUnit:RegisterEvent("Phase_2", 1000, 0)
    end
    end
    
    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 60 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Mhmph... I didn't know this fight would last so long...")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 19000, 0)
    pUnit:RegisterEvent("ShadowBlast", 12000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("FrostCleave", 11000, 0)
    pUnit:RegisterEvent("Phase_3", 1000, 0)
    end
    end
    
    Function Phase_3(pUnit, Event)
    if pUnit:GetHealthPct() <= 40 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I see the end of the fight is near... I may still make it if I open all my power... Behold mortals... MY TRUE POWER!!!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 17000, 0)
    pUnit:RegisterEvent("ShadowBlast", 11000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("Enrage2", 7000, 0)
    pUnit:RegisterEvent("FrostCleave", 10000, 0)
    pUnit:RegisterEvent("Summon", 1000, 1)
    end
    end
    
    function Summon(pUnit, Event)
    pUnit:RemoveEvents()
    x = pUnit:GetX()
    y = pUnit:GetY()
    z = pUnit:GetZ()
    o = pUnit:GetO()
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    end
    
    
    function FireBreath(pUnit, Event)
    pUnit:CastSpellOnTarget(49110, pUnit:GetMainTank())
    end
    
    function TimeStop(pUnit, Event)
    pUnit:CastSpell(60074)
    end
    
    function ShadowBlast(pUnit, Event)
    pUnit:CastSpellOnTarget(41078, pUnit:GetMainTank())
    end
    
    function Enrage(pUnit, Event)
    pUnit:CastSpell(26041)
    end
    
    function Enrage2(pUnit, Event)
    pUnit:CastSpell(42705)
    end
    
    function FrostCleave(pUnit, Event)
    pUnit:CastSpellOnTarget(51857, pUnit:GetMainTank())
    end
    
    
    RegisterUnitEvent(101101, 1, "EpochBolie_OnCombat")
    RegisterUnitEvent(101101, 2, "EpochBolie_LeaveCombat")
    RegisterUnitEvent(101101, 4, "EpochBolie_OnDied")
    Can someone fix it... :confused:
    Last edited by bolie2008; 05-22-2009 at 08:48 AM. Reason: More errors

  4. #4
    bolie2008's Avatar Member
    Reputation
    2
    Join Date
    Nov 2008
    Posts
    12
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Anyone please help I wanna fix this so bad...

  5. #5
    Dynashock's Avatar Contributor

    Reputation
    176
    Join Date
    Nov 2007
    Posts
    203
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hm, change 'Function' to 'function'. Lua is case-sensitive, iirc, so now it sees Function as a variable, instead of as a function.

    You need to change line 11 too, if GetHealthPct() <= 85 then, to if pUnit:GetHealthPct() <= 85 then

  6. #6
    bolie2008's Avatar Member
    Reputation
    2
    Join Date
    Nov 2008
    Posts
    12
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Its loaded... so the LUA is alright now.
    BUT... my mob still doesn't do what he's supposed to do...
    He doesn't even say something

  7. #7
    Dynashock's Avatar Contributor

    Reputation
    176
    Join Date
    Nov 2007
    Posts
    203
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That's because you don't have a onCombat hook registered. You used to have it in your first version but you have removed it now? I'm talking about:
    Code:
    function EpochBolie_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Our destiny has lead us to this place... and now we fight...")
    pUnit:RegisterEvent("ShadowBlast", 15000, 0)
    pUnit:RegisterEvent("Phase_1", 1000, 0)
    end
    Without that it won't do anything on entering combat, it'll only do stuff when you kill him or leave combat because those hooks are registered. So putting that part back should fix it.

  8. #8
    bolie2008's Avatar Member
    Reputation
    2
    Join Date
    Nov 2008
    Posts
    12
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You sir, are one big LUA pro! It now works except one thing...

    function EpochBolie_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Our destiny has lead us to this place... and now we fight...")
    pUnit:RegisterEvent("ShadowBlast", 15000, 0)
    pUnit:RegisterEvent("Phase_1", 1000, 0)
    end

    function EpochBolie_OnDied(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "I guess everything is as... time wanted to...")
    pUnit:RemoveEvents()
    end

    function EpochBolie_LeaveCombat(pUnit, Event)
    pUnit:RemoveEvents()
    end

    function Phase_1(pUnit, Event)
    if pUnit:GetHealthPct() <= 85 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I guess fate is on your side... I'm injured already... But I've seen my future and know I will win this battle!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop",21000, 0)
    pUnit:RegisterEvent("ShadowBlast",15000, 0)
    pUnit:RegisterEvent("Phase_2", 1000, 0)
    end
    end

    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 60 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Mhmph... I didn't know this fight would last so long...")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 19000, 0)
    pUnit:RegisterEvent("ShadowBlast", 12000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("FrostCleave", 11000, 0)
    pUnit:RegisterEvent("Phase_3", 1000, 0)
    end
    end

    function Phase_3(pUnit, Event)
    if pUnit:GetHealthPct() <= 40 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I see the end of the fight is near... I may still make it if I open all my power... Behold mortals... MY TRUE POWER!!!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 17000, 0)
    pUnit:RegisterEvent("ShadowBlast", 11000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("Enrage2", 7000, 0)
    pUnit:RegisterEvent("FrostCleave", 10000, 0)
    pUnit:RegisterEvent("Summon", 1000, 1)
    end
    end

    function Summon(pUnit, Event)
    pUnit:RemoveEvents()
    x = pUnit:GetX()
    y = pUnit:GetY()
    z = pUnit:GetZ()
    o = pUnit:GetO()
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    end


    function FireBreath(pUnit, Event)
    pUnit:CastSpellOnTarget(49110, pUnit:GetMainTank())
    end

    function TimeStop(pUnit, Event)
    pUnit:CastSpell(60074)
    end

    function ShadowBlast(pUnit, Event)
    pUnit:CastSpellOnTarget(41078, pUnit:GetMainTank())
    end

    function Enrage(pUnit, Event)
    pUnit:CastSpell(26041)
    end

    function Enrage2(pUnit, Event)
    pUnit:CastSpell(42705)
    end

    function FrostCleave(pUnit, Event)
    pUnit:CastSpellOnTarget(51857, pUnit:GetMainTank())
    end


    RegisterUnitEvent(101101, 1, "EpochBolie_OnCombat")
    RegisterUnitEvent(101101, 2, "EpochBolie_LeaveCombat")
    RegisterUnitEvent(101101, 4, "EpochBolie_OnDied")
    In this LUA you see the 80% working script but there are a few bugs.
    1. The Summoned mobs dont disappear
    2. His Frost Cleave spell is cast on himself.
    3. FireBreath is cast on himself
    4. All spells are instant which isn't supposed to be like that...
    Can you fix those pleeeaaase... I already +Rep 'ed you
    Last edited by bolie2008; 05-22-2009 at 12:21 PM.

  9. #9
    controlsx2's Avatar Member
    Reputation
    16
    Join Date
    Jun 2007
    Posts
    223
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    1) Not quite sure of that
    2) If its an AoE then remove the pUnit:CastSpellOnTarget(51857, pUnit:GetMainTank()) and put pUnit:CastSpell(51857)
    3) Same as Above
    4) Go through your code replace all pUnit:CastSpellOnTarget with pUnit:FullCastSpellOnTarget

    so try this

    function EpochBolie_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Our destiny has lead us to this place... and now we fight...")
    pUnit:RegisterEvent("ShadowBlast", 15000, 0)
    pUnit:RegisterEvent("Phase_1", 1000, 0)
    end

    function EpochBolie_OnDied(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "I guess everything is as... time wanted to...")
    pUnit:RemoveEvents()
    end

    function EpochBolie_LeaveCombat(pUnit, Event)
    pUnit:RemoveEvents()
    end

    function Phase_1(pUnit, Event)
    if pUnit:GetHealthPct() <= 85 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I guess fate is on your side... I'm injured already... But I've seen my future and know I will win this battle!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop",21000, 0)
    pUnit:RegisterEvent("ShadowBlast",15000, 0)
    pUnit:RegisterEvent("Phase_2", 1000, 0)
    end
    end

    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 60 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Mhmph... I didn't know this fight would last so long...")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 19000, 0)
    pUnit:RegisterEvent("ShadowBlast", 12000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("FrostCleave", 11000, 0)
    pUnit:RegisterEvent("Phase_3", 1000, 0)
    end
    end

    function Phase_3(pUnit, Event)
    if pUnit:GetHealthPct() <= 40 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I see the end of the fight is near... I may still make it if I open all my power... Behold mortals... MY TRUE POWER!!!")
    pUnit:RegisterEvent("FireBreath", 4000, 0)
    pUnit:RegisterEvent("TimeStop", 17000, 0)
    pUnit:RegisterEvent("ShadowBlast", 11000, 0)
    pUnit:RegisterEvent("Enrage", 5000, 0)
    pUnit:RegisterEvent("Enrage2", 7000, 0)
    pUnit:RegisterEvent("FrostCleave", 10000, 0)
    pUnit:RegisterEvent("Summon", 1000, 1)
    end
    end

    function Summon(pUnit, Event)
    pUnit:RemoveEvents()
    x = pUnit:GetX()
    y = pUnit:GetY()
    z = pUnit:GetZ()
    o = pUnit:GetO()
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    pUnit:SpawnCreature(101102, x, y, z, o, 14, 60000)
    end


    function FireBreath(pUnit, Event)
    pUnit:CastSpell(49110)
    end

    function TimeStop(pUnit, Event)
    pUnit:CastSpell(60074)
    end

    function ShadowBlast(pUnit, Event)
    pUnit:FullCastSpellOnTarget(41078, pUnit:GetMainTank())
    end

    function Enrage(pUnit, Event)
    pUnit:CastSpell(26041)
    end

    function Enrage2(pUnit, Event)
    pUnit:CastSpell(42705)
    end

    function FrostCleave(pUnit, Event)
    pUnit:CastSpell(51857)
    end


    RegisterUnitEvent(101101, 1, "EpochBolie_OnCombat")
    RegisterUnitEvent(101101, 2, "EpochBolie_LeaveCombat")
    RegisterUnitEvent(101101, 4, "EpochBolie_OnDied")

Similar Threads

  1. [ArcEmu] Fail on load when using lua scripts
    By goldfish1 in forum WoW EMU Questions & Requests
    Replies: 1
    Last Post: 02-20-2011, 04:03 AM
  2. [Help] LUA Script + GO info
    By Hellgawd in forum World of Warcraft Emulator Servers
    Replies: 4
    Last Post: 02-12-2008, 05:06 AM
  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 01:39 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