Alright here is the LUA script I'm using.
Code:
function Teleporter_EnterCombat(Unit, Event)
Unit:SendChatMessage(12, 0, "I OWN u")
Unit:RegisterEvent("phase1", 9000, 0)
end
function phase1(Unit, Event)
if Unit:GetHealthPct() < 75 then
Unit:RemoveEvents()
Unit:SendChatMessage(12, 0, "You don't stand a chance!")
Unit:FullCastSpellOnTarget(38946, Unit:GetRandomPlayer(0))
Unit:FullCastSpellOnTarget(34119, 9000)
Unit:RegisterEvent("phase2", 9000, 0)
end
end
function phase2(Unit, Event)
if Unit:GetHealthPct() < 55 then
Unit:RemoveEvents()
Unit:SendChatMessage(12, 0, "You have great power, but it ends now")
Unit:CastSpell(41107)
end
end
RegisterUnitEvent(9000, 1, "Teleporter_EnterCombat")
When I fix one problem, another one comes up =\
Right now I have one I can't get passed
bad argument #1 to 'FullCastSpellOnTarget' <Unit expected, got number>
Isn't FullCastSpellOnTarget supposed to be
FullCastSpellOnTarget(spellID, unitID)
Thanks for your time.