Server doing wrong lua :OOOO menu

User Tag List

Results 1 to 6 of 6
  1. #1
    Warriar's Avatar Active Member
    Reputation
    31
    Join Date
    May 2009
    Posts
    149
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Server doing wrong lua :OOOO

    Well, On the server I'm running, I put each lua in seperetly and the npc casts those spells, I have Wariror, Assassin and Hexlord for example. I put them in one by one, as in I put one in start the server up and then take it out and put another one in and restart the server and they work fine! there all casting the spells given to them

    However, When I put all 3 of them in at once, The warrior starts casting Hexlord moves, The hexlord is casting his moves and the Assassin is casting hexlord moves too! they still say the things that were in the lua there just casting diffferent moves o.O

    +Rep For ppl that help

    Code:
    function headsplitter_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Dabin Shall Prevail Mon'")
    pUnit:RemoveEvents()
    pUnit:RegisterEvent("Phase_1", 100, 0)
    end
    
    function headsplitter_OnLeaveCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Run Maggots")
    end
    
    function headsplitter_OnDied(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "My Death .. Does not prove Anything!")
    end
    
    function Phase_1(pUnit, Event)
    if pUnit:GetHealthPct() <= 95 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Just Try to Kill me Mon'")
    pUnit:RegisterEvent("whirlw", 10000, 0)
    pUnit:RegisterEvent("thunderc", 100, 1)
    pUnit:RegisterEvent("thunderc", 25000, 0)
    pUnit:RegisterEvent("Phase_2", 100, 0)
    end
    end
    
    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 12 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I will NOT die!")
    pUnit:RegisterEvent("enrage", 100, 1)
    end
    end
    
    function whirlw(pUnit, Event)
    pUnit:CastSpell(26084)
    end
    
    function thunderc(pUnit, Event)
    pUnit:CastSpell(60019)
    end
    
    function enrage(pUnit, Event)
    pUnit:CastSpell(41447)
    end
    
    RegisterUnitEvent(66600, 1, "headsplitter_OnCombat")
    RegisterUnitEvent(66600, 2, "headsplitter_OnLeaveCombat")
    RegisterUnitEvent(66600, 4, "headsplitter_OnDied")
    Code:
    function hexlord_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Resistance is useless mon''")
    pUnit:RemoveEvents()
    pUnit:RegisterEvent("Phase_1", 100, 0)
    end
    
    function hexlord_OnLeaveCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Tha Hexlord has won mon'")
    end
    
    function hexlord_OnDied(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "My Death .. Does not prove Anything!")
    end
    
    function Phase_1(pUnit, Event)
    if pUnit:GetHealthPct() <= 95 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Bring it on!'")
    pUnit:RegisterEvent("hex", 10000, 0)
    pUnit:RegisterEvent("hex", 100, 1)
    pUnit:RegisterEvent("naturesh", 8000, 0)
    pUnit:RegisterEvent("Phase_2", 100, 0)
    end
    end
    
    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 12 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I will NOT die!")
    pUnit:RegisterEvent("enrage", 100, 1)
    end
    end
    
    function hex(pUnit, Event)
    pUnit:FullCastSpellOnTarget(40400, pUnit:GetRandomPlayer(0))
    end
    
    function naturesh(pUnit, Event)
    pUnit:FullCastSpellOnTarget(61668, pUnit:GetMainTank())
    end
    
    function enrage(pUnit, Event)
    pUnit:CastSpell(41447)
    end
    
    RegisterUnitEvent(66601, 1, "hexlord_OnCombat")
    RegisterUnitEvent(66601, 2, "hexlord_OnLeaveCombat")
    RegisterUnitEvent(66601, 4, "hexlord_OnDied")
    Code:
    function assassin_OnCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "Join us! You will be given power beyond your imagination mon''")
    pUnit:RemoveEvents()
    pUnit:RegisterEvent("Phase_1", 100, 0)
    end
    
    function assassin_OnLeaveCombat(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "You Better Run!'")
    end
    
    function assassin_OnDied(pUnit, Event)
    pUnit:SendChatMessage(14, 0, "My Death .. Does not prove Anything!")
    end
    
    function Phase_1(pUnit, Event)
    if pUnit:GetHealthPct() <= 95 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "Bring it on!'")
    pUnit:RegisterEvent("fan", 10000, 0)
    pUnit:RegisterEvent("fan", 100, 1)
    pUnit:RegisterEvent("ss", 8000, 0)
    pUnit:RegisterEvent("Phase_2", 100, 0)
    end
    end
    
    function Phase_2(pUnit, Event)
    if pUnit:GetHealthPct() <= 12 then
    pUnit:RemoveEvents()
    pUnit:SendChatMessage(14, 0, "I will NOT die!")
    pUnit:RegisterEvent("enrage", 100, 1)
    end
    end
    
    function fan(pUnit, Event)
    pUnit:CastSpell(63753)
    end
    
    function ss(pUnit, Event)
    pUnit:FullCastSpellOnTarget(59409, pUnit:GetMainTank())
    end
    
    function enrage(pUnit, Event)
    pUnit:CastSpell(41447)
    end
    
    RegisterUnitEvent(66602, 1, "assassin_OnCombat")
    RegisterUnitEvent(66602, 2, "assassin_OnLeaveCombat")
    RegisterUnitEvent(66602, 4, "assassin_OnDied")
    Theres the Lua's
    Last edited by Warriar; 07-08-2009 at 08:07 PM.

    Server doing wrong lua :OOOO
  2. #2
    Gastricpenguin's Avatar Legendary
    Reputation
    980
    Join Date
    Feb 2007
    Posts
    2,236
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Do your functions have UNIQUE names? If a function name is repeated twice, you will receive errors. Post the scripts IN CODE TAGS.
    Life Puzzler WoW - Website | Forums

  3. #3
    Warriar's Avatar Active Member
    Reputation
    31
    Join Date
    May 2009
    Posts
    149
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    EDIT: I tested it, i changed enrage names and it still does the same thing :*(
    Last edited by Warriar; 07-08-2009 at 08:25 PM.

  4. #4
    Gastricpenguin's Avatar Legendary
    Reputation
    980
    Join Date
    Feb 2007
    Posts
    2,236
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Welllll. It could be the fact you have 3 different "Phase_1()" functions. Like I said before, you CANNOT repeat functions.
    Life Puzzler WoW - Website | Forums

  5. #5
    Warriar's Avatar Active Member
    Reputation
    31
    Join Date
    May 2009
    Posts
    149
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    my god .. you sir are good at this

  6. #6
    Contox's Avatar Member
    Reputation
    1
    Join Date
    May 2008
    Posts
    15
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Warriar View Post
    my god .. you sir are good at this
    Ofcourse he is. He is an Emulation Expert :wave:

Similar Threads

  1. [LUA/SQL] What could I be doing wrong with ALL of my scripts?
    By davidknag in forum WoW EMU Questions & Requests
    Replies: 5
    Last Post: 03-15-2010, 02:46 PM
  2. What am I doing wrong WoW.exe does not appear on WPE.
    By Eliteplague in forum World of Warcraft Emulator Servers
    Replies: 3
    Last Post: 10-30-2007, 04:21 AM
  3. [Question] errr what am i doing wrong?
    By Demonshade in forum WoW ME Questions and Requests
    Replies: 9
    Last Post: 10-10-2007, 04:22 AM
  4. DynDNS help. What am I doing wrong?
    By xxtennisdudexx in forum World of Warcraft Emulator Servers
    Replies: 21
    Last Post: 09-23-2007, 05:23 PM
  5. what am i doing wrong...
    By tiliqua in forum WoW ME Questions and Requests
    Replies: 2
    Last Post: 09-16-2007, 01:18 AM
All times are GMT -5. The time now is 08:36 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