PDA

View Full Version : [LUA ++] Boss Script


~Virus~
05-04-2009, 03:43 AM
********************************
* WoWRevamped *
* Entertainment *
* LUA++ Boss Script *
* *
********************************

This Is A Script made By the Developing and Scripting
Team Of WoWRevamped Please Read this Below and Follow
the License Agreement.This a Script That Was Made For
Our Server Please I Request Do Not Rip This. Thank You


~~End of License Agreement
-- WoWRevamped staff, May 3 , 2009 {11:35}. ]]
function Boss_HolyNovaRepeat(pUnit, event)
pUnit:CastSpell(23858)
pUnit:RegisterEvent("Boss_HolyNova", math.random(26000, 31000), 1)
end

function Boss_HolyNova(pUnit, event)
pUnit:CastSpell(23858)
pUnit:RegisterEvent("Boss_HolyNovaRepeat", math.random(26000, 31000), 1)
end

function Boss_HolyFireRepeat(pUnit, event)
pUnit:FullCastSpellOnTarget(23860, pUnit:GetMainTank())
pUnit:RegisterEvent("Boss_HolyFire", math.random(18000, 22000), 1)
end

function Boss_HolyFire(pUnit, event)
pUnit:FullCastSpellOnTarget(23860, pUnit:GetMainTank())
pUnit:RegisterEvent("Boss_HolyFireRepeat", math.random(18000, 22000), 1)
end

function Boss_Serpent(pUnit, event)
local serpenttarget=pUnit:GetRandomPlayer(0);
pUnit:SpawnCreature(14884, serpenttarget:GetX(), serpenttarget:GetY(), serpenttarget:GetZ(), serpenttarget:GetO(), 14, 0)
end

function Boss_Renew(pUnit, event)
pUnit:CastSpell(23895)
end

function Boss_PoisonCloud(pUnit, event)
pUnit:CastSpell(23861)
end

function Boss_VenomSpitRepeat(pUnit, event)
pUnit:FullCastSpellOnTarget(23862, pUnit:GetRandomPlayer(0))
pUnit:RegisterEvent("Boss_VenomSpit", math.random(14000, 18000), 1)
end

function Boss_VenomSpit(pUnit, event)
pUnit:FullCastSpellOnTarget(23862, pUnit:GetRandomPlayer(0))
pUnit:RegisterEvent("Boss_VenomSpitRepeat", math.random(14000, 18000), 1)
end

function Boss_Phasetwo(pUnit, event)
if pUnit:GetHealthPct() < 51 then
pUnit:RemoveEvents()
pUnit:SendChatMessage(14, 0, "Let the coils of hate unfurl!")
pUnit:SetModel(9134)
pUnit:CastSpell(23849)
pUnit:CastSpell(23861)
pUnit:RegisterEvent("Boss_PoisonCloud", 22000, 0)
pUnit:RegisterEvent("Boss_VenomSpit", math.random(14000, 18000), 1)
end
end

function Boss_OnEnterCombat(pUnit, event)
pUnit:RegisterEvent("Boss_HolyNova", math.random(26000, 31000), 1)
pUnit:RegisterEvent("Boss_HolyFire", math.random(18000, 22000), 1)
pUnit:RegisterEvent("Boss_Serpent", 45000, 0)
pUnit:RegisterEvent("Boss_Renew", 50000, 0)
pUnit:RegisterEvent("Boss_Phasetwo", 1000, 0)
end

RegisterUnitEvent(14507, 1, "Boss_OnEnterCombat")

function Boss_OnWipe(pUnit, event)
if pUnit:IsAlive() == true then
pUnit:SetModel(15217)
pUnit:RemoveEvents()
else
pUnit:SendChatMessage(14, 0, "Ssserenity..at lassst!")
end
end

RegisterUnitEvent(14507, 2, "Boss_OnWipe")

function Boss_OnDie(pUnit, event)
pUnit:RemoveEvents()
end

RegisterUnitEvent(14507, 4, "Boss_OnDie")

--Parasitic Serpent AI
function Serpent_OneTimeBite(pUnit, event)
pUnit:FullCastSpellOnTarget(23865, pUnit:GetClosestPlayer())
end

function Serpent_Bite(pUnit, event)
pUnit:FullCastSpellOnTarget(23865, pUnit:GetClosestPlayer())
end

function Serpent_OnEnterCombat(pUnit, event)
pUnit:RegisterEvent("Serpent_OneTimeBite", 2000, 1)
pUnit:RegisterEvent("Serpent_Bite", 14000, 0)
end

RegisterUnitEvent(14884, 1, "Serpent_OnEnterCombat")

function Serpent_OnWipe(pUnit, event)
pUnit:RemoveEvents()
end

RegisterUnitEvent(14884, 2, "Serpent_OnWipe")

function Serpent_OnDie(pUnit, event)
pUnit:RemoveEvents()
end

RegisterUnitEvent(14884, 4, "Serpent_OnDie")


Enjoy This Script , If any Errors or Problems are Caused Please
Repost under this topic and i will fix the solution this is not ripped
completely hand made by WoWRevamped Developing and Scripting
Team.

Sincerely
~WoWRevamped Entertainment

stoneharry
05-04-2009, 07:31 AM
Err, thats not Lua++, also Lua++ is just a edited version of normal Lua as is the same with Lua#.
A word of advice change the CastSpells to FullCastSpells as theres an old error where the spell will not trigger properly and just do the visual if you have cast spell (on some Lua engines, not all). +Rep

Alvanaar
05-04-2009, 08:05 AM
(on some Lua engines, not all).

On the bad ones :P

Another boring boss script... Oh well...

Also, that's not specific to Lua++. But good work, Virus. :)

~Virus~
05-04-2009, 05:20 PM
Thanx guys well that means never trust a D3scene
scripting LUA++ tut ever again and i give both of you
guys

+rep