Hey all.. im making a boss that is supposed to shout things out, cast spells etc, and i think i got my LUA script to work, Arcemu doesnt give me any LUA errors when LuaHypArc loads up anyway. So i go in-game and i spawn my boss and i attack it, but it never does anything except attack me? I dont know if the script didnt get loaded or if i did something wrong. Here it is:
Code:
-- Epic Boss Fight
--Functions
function Random_OnCombat(pUnit, Event)
pUnit:SendChatMessage(14, 0, "FOOLS! Your pathetic armor and weaponry is no match for the power of the SCOURGE!")
pUnit:RegisterEvent("Combat_Buff", 1000, 0)
end
function Combat_Buff(pUnit, Event)
pUnit:FullCastSpell(55336)
end
function Rage_Start(pUnit, Event)
if pUnit:GetHealthPct(75)then
pUnit:RemoveEvents()
pUnit:SetScale(1.2)
pUnit:FullCastSpell(6742)
pUnit:SendChatMessage(14, 0, "Ha! You think I'm going to let your pathetic efforts thwart me?!")
end
function Random_OnLeave(pUnit, Event)
pUnit:SendChatMessage(14, 0, "Yes! Run you pathetic scum! You are worthless in the eyes of the undead!")
pUnit:RemoveEvent()
end
function Random_OnDie(pUnit, Event)
pUnit:SendChatMessage(14, 0, "I.. am.. released... master... Forgive me my lord!")
end
function Random_OnTargetDie(pUnit, Event)
pUnit:SendChatMessage(14, 0, "Your soul will find no rest here!")
end
--RegisterUnitEvents
RegisterUnitEvent(96000, 1, "Random_OnCombat")
RegisterUnitEvent(96000, 2, "Random_OnLeave")
RegisterUnitEvent(96000, 4, "Random_OnDie")
RegisterUnitEvent(96000, 3, "Random_OnTargetDie")
RegisterUnitEvent(96000, 5, "Rage_Start")
end
If someone could point out what is wrong or give me some tips that would be great, thanks.