chaosnight
Would you like to react to this message? Create an account in a few clicks or log in to continue.
chaosnight

Rednightwow Forums
 
HomeHome  Latest imagesLatest images  SearchSearch  RegisterRegister  Log in  

 

 sharrior boss script made by sharrior

Go down 
3 posters
AuthorMessage
sharrior
GM
GM
sharrior


Posts : 78
Join date : 2008-09-25
Age : 28
Location : Norway

sharrior boss script made by sharrior Empty
PostSubject: sharrior boss script made by sharrior   sharrior boss script made by sharrior Icon_minitimeWed Jan 14, 2009 8:55 am

Code:
local spawnID = 123412

    local NPCNAME = Sharrior
   
       local SPAWNNAME = Sharrior
      
          local NPCID = 761298






function NPCNAME_OnCombat (Unit, Event)
        pUnit:SendChatMessage (12, 0, "Im Going to pwn you!")
      pUnit:RegisterEvent("NPCNAME_Spell", 10000, 10)
      pUnit:RegisterEvent("NPCNAME_Aoe", 20000, 10)
      pUnit:RegisterEvent("NPCNAME_CheckA", 30000, 20)
      pUnit:RegisterEvent("NPCNAME_CheckB", 35000, 20)
      pUnit:RegisterEvent("NPCNAME_CheckC", 40000, 20)
      pUnit:RegisterEvent("NPCNAME_CheckD", 40000, 20)
      pUnit:RegisterEvent("NPCNAME_CheckE", 60000, 20)
      pUnit:RegisterEvent("NPCNAME_Summon", 40000, 1)
      pUnit:RegisterEvent("NPCNAME_Scale", 900000, 2)
      pUnit:RegisterEvent("NPCNAME_Model", 100000, 2)
end

function NPCNAME_Spell (pUnit, Event)
        pUnit:FullCastSpellOnTarget(11661, pUnit:GetRandomPlayer(0))
      
end

function NPCNAME_Aoe (pUnit, Event)
        pUnit: FullCast (11661)
end


function NPCNAME_CheckA (pUnit, Event)
        if pUnit:GetHealthPct()  < 80 then
      pUnit:SendChatMessage (12, 0, "so you think you got me now? haha what a joke")
      pUnit:CastSpellOnTarget(25, pUnit:GetMainTank())
   end
end


function NPCNAME_CheckB(pUnit, Event)
        if pUnit:GetHealthPct() < 50 then
      pUnit:SendChatMessage (12, 0, "I am ready for another round,bring it on!")
      pUnit:CastSpellOnTarget(5, pUnit:GetClosestPlayer(0))
   end
end

function NPCNAME_CheckC(pUnit, Event)
        if pUnit:GetHealthPct() < 1 then
      pUnit:SendChatMessage (12, 0, "NOOO NOT AGAIN! just kidding")
      pUnit:CastSpell(48063)
      pUnit:CastSpell(48063)
   end
end


function NPCNAME_CheckD(pUnit, Event)
        if pUnit:GetHealthPct() < 25 then
      pUnit:SendChatMessage (12, 0, "Now you made me angry!")
      pUnit:SetModel(11852)
   end
end


function NPCNAME_CheckE(pUnit, Event)
        if pUnit:GetHealthPct() < 20 then
      pUnit:SendChatMessage(12, 0, "Im going to crush you now!")
      pUnit:SetScale(5)
   end
end




function NPCNAME_Summon (pUnit, Event)
        x = pUnit:GetX();
      y = pUnit:GetY();
      z = pUnit:GetZ();
      o = pUnit:GetO();
      pUnit:SendChatMessage(12, 0, "Come forth mighty mc.Avery!")
      pUnit:SpawnCreature (82000, x, y, z, o, 1, 36000);
end


function NPCNAME_Scale (pUnit, Event)
        pUnit:SetScale  (3)
end


function NPCNAME_Model (pUnit, Event)
        pUnit:SetModel (17523)
end


function NPCNAME_OnDied (pUnit, Event)
        pUnit:SendChatMessage(12, 0, "NOOO,I CANT DIE! I AM IMMORTAL")
        pUnit:RemoveEvents()
end

function NPCNAME_OnKilledTarget (pUnit, Event)
        pUnit:SendChatMessage(12, 0, "Wha ha ha,he just died")
      pUnit:CastSpellOnTarget(25, pUnit:GetClosestPlayer)
end

function NPCNAME_OnLeaveCombat (pUnit, Event)
        pUnit:SendChatMessage(12, 0, "They just ran away")
      pUnit:RemoveEvents()
end

RegisterUnitEvent(123412, 1, "NPCNAME_OnCombat")
RegisterUnitEvent(123412, 2, "NPCNAME_OnKilledTarget")
RegisterUnitEvent(123412, 3, "NPCNAME_OnLeaveCombat")
RegisterUnitEvent(123412, 4, "NPCNAME_OnDied")




What you think?`not bad for my first Lua script,but I dunno if it works Razz
Back to top Go down
streetdeath
GM
GM
streetdeath


Posts : 23
Join date : 2008-10-02
Age : 31
Location : BOB (england):P

sharrior boss script made by sharrior Empty
PostSubject: Re: sharrior boss script made by sharrior   sharrior boss script made by sharrior Icon_minitimeSat Jan 24, 2009 3:43 pm

nice good work better than i could ever do Razz hope it works


it is for a boss right?

which means if it is we can then use that as a template for other bosses???
Back to top Go down
sharrior
GM
GM
sharrior


Posts : 78
Join date : 2008-09-25
Age : 28
Location : Norway

sharrior boss script made by sharrior Empty
PostSubject: Re: sharrior boss script made by sharrior   sharrior boss script made by sharrior Icon_minitimeSat Jan 24, 2009 3:49 pm

yes you can,but that is just the basic stuff lol.
Back to top Go down
Swanitalia
Admin
Admin
Swanitalia


Posts : 161
Join date : 2008-09-22
Location : I dont know

sharrior boss script made by sharrior Empty
PostSubject: Re: sharrior boss script made by sharrior   sharrior boss script made by sharrior Icon_minitimeSat Jan 24, 2009 8:07 pm

i have a script for your boss, but this is nice. I will try it out when i try my script out too
Back to top Go down
http://rednight.selfip.net
sharrior
GM
GM
sharrior


Posts : 78
Join date : 2008-09-25
Age : 28
Location : Norway

sharrior boss script made by sharrior Empty
PostSubject: Re: sharrior boss script made by sharrior   sharrior boss script made by sharrior Icon_minitimeSun Jan 25, 2009 8:55 am

;P thanks.
What do you think about the 2 other Lua boss scripts I made?
Back to top Go down
Swanitalia
Admin
Admin
Swanitalia


Posts : 161
Join date : 2008-09-22
Location : I dont know

sharrior boss script made by sharrior Empty
PostSubject: Re: sharrior boss script made by sharrior   sharrior boss script made by sharrior Icon_minitimeTue Jan 27, 2009 9:25 am

they are good too
Back to top Go down
http://rednight.selfip.net
Sponsored content





sharrior boss script made by sharrior Empty
PostSubject: Re: sharrior boss script made by sharrior   sharrior boss script made by sharrior Icon_minitime

Back to top Go down
 
sharrior boss script made by sharrior
Back to top 
Page 1 of 1
 Similar topics
-
» Sharrior boss script
» 2 lua bosses made by sharrior
» Sharrior's introducing himself.
» New problem(not server side) ~sharrior~
» anuthar lua script

Permissions in this forum:You cannot reply to topics in this forum
chaosnight :: Rednight server forums :: Coding-
Jump to: