Code:
INSERT INTO creature_spawns (id,entry,map,position_x,position_y,position_z,orientation,movetype,displayid,faction,flags,bytes,bytes2,emote_state,npc_respawn_link,channel_spell,channel_target_sqlid,channel_target_sqlid_creature,standstate)
VALUES ('244150','909090','530','-781,641','6943,31','33,3279','2,53134','0','21607','14','0','0','0','0','0','0','0','0','0')
INSERT INTO creature_names (entry, name, subname, info_str, Flags1, type, family, rank, male_displayid, female_displayid, male_displayid2, female_displayid2, civilian, leader) VALUES ('909090','Shandroi','Master of Elements','','0','4','0','3','21607','0','0','0','0','0')
INSERT INTO creature_proto (entry, minlevel, maxlevel, faction, minhealth, maxhealth, mana, scale, npcflags, attacktime, mindamage, maxdamage, rangedattacktime, rangedmindamage, rangedmaxdamage, mountdisplayid, equipmodel1, equipmodel2, equipmodel3, respawntime, armor, resistance1, resistance2, resistance3, resistance4, resistance5, resistance6, combat_reach, auras, boss, money, invisibility_type, death_state, walk_speed, run_speed, fly_speed) VALUES ('909090','73','73','14','3000000','3000000','1000000','0','1500','10000','11500','0','0','0','0','0','0','0','36000','1000','0','0','0','0','0','0','1','0','0','0','0','0','2.5','8','14')
INSERT INTO creature_names (entry, name, subname, info_str, Flags1, type, family, rank, male_displayid, female_displayid, male_displayid2, female_displayid2, civilian, leader) VALUES ('909092','Earth Elemental','','','0','4','0','1','14511','0','0','0','0','0')
INSERT INTO creature_proto (entry, minlevel, maxlevel, faction, minhealth, maxhealth, mana, scale, npcflags, attacktime, mindamage, maxdamage, rangedattacktime, rangedmindamage, rangedmaxdamage, mountdisplayid, equipmodel1, equipmodel2, equipmodel3, respawntime, armor, resistance1, resistance2, resistance3, resistance4, resistance5, resistance6, combat_reach, auras, boss, money, invisibility_type, death_state, walk_speed, run_speed, fly_speed) VALUES ('909092','70','70','14','200000','200000','1000000','0','1500','3000','4000','0','0','0','0','0','0','0','0','1000','0','0','0','0','0','0','1','0','0','0','0','0','2.5','8','14')
INSERT INTO creature_names (entry, name, subname, info_str, Flags1, type, family, rank, male_displayid, female_displayid, male_displayid2, female_displayid2, civilian, leader) VALUES ('909091','Fire Elemental','','','0','4','0','1','1204','0','0','0','0','0')
INSERT INTO creature_proto (entry, minlevel, maxlevel, faction, minhealth, maxhealth, mana, scale, npcflags, attacktime, mindamage, maxdamage, rangedattacktime, rangedmindamage, rangedmaxdamage, mountdisplayid, equipmodel1, equipmodel2, equipmodel3, respawntime, armor, resistance1, resistance2, resistance3, resistance4, resistance5, resistance6, combat_reach, auras, boss, money, invisibility_type, death_state, walk_speed, run_speed, fly_speed) VALUES ('909091','70','70','14','200000','200000','1000000','0','1500','3000','4000','0','0','0','0','0','0','0','0','1000','0','300','0','0','0','0','1','0','0','0','0','0','2.5','8','14')
INSERT INTO creature_names (entry, name, subname, info_str, Flags1, type, family, rank, male_displayid, female_displayid, male_displayid2, female_displayid2, civilian, leader) VALUES ('909093','Water Elemental','','','0','4','0','1','525','0','0','0','0','0')
INSERT INTO creature_proto (entry, minlevel, maxlevel, faction, minhealth, maxhealth, mana, scale, npcflags, attacktime, mindamage, maxdamage, rangedattacktime, rangedmindamage, rangedmaxdamage, mountdisplayid, equipmodel1, equipmodel2, equipmodel3, respawntime, armor, resistance1, resistance2, resistance3, resistance4, resistance5, resistance6, combat_reach, auras, boss, money, invisibility_type, death_state, walk_speed, run_speed, fly_speed) VALUES ('909093','70','70','14','200000','200000','1000000','0','1500','3000','4000','0','0','0','0','0','0','0','0','1000','0','0','0','300','0','0','1','0','0','0','0','0','2.5','8','14')
And here is the script(save as .lua in ure scripts folder)
Code:
function Master_OnCombat(Unit, Event)
Unit:SendChatMessage(12, 0, "What did I say about comeing here and disturb me??")
Unit:RegisterEvent("Master_CHainL", 6000, 0)
Unit:RegisterEvent("Master_phaxe1",1000,0)
end
function Master_CHainL(pUnit, Event)
pUnit:FullCastSpellOnTarget(28293, pUnit:GetRandomPlayer(0))
end
function Earthele_Spawn(pUnit, Event)
pUnit:SpawnCreature(909092, -769.899170, 6965.648926, 33.1979, 2.920131, 16, 60000)
pUnit:SpawnCreature(909092, -800.942017, 6919.056152, 34.28933, 2446542, 16, 60000)
end
function WaterEle_Spawn2(pUnit, Event)
pUnit:SpawnCreature(909093, -769.899170, 6965.648926, 33.1979, 2.920131, 16, 60000)
pUnit:SpawnCreature(909093, -800.942017, 6919.056152, 34.28933, 2446542, 16, 60000)
end
function FireEle_Spawn3(pUnit, Event)
pUnit:SpawnCreature(909091, -769.899170, 6965.648926, 33.1979, 2.920131, 16, 60000)
pUnit:SpawnCreature(909091, -800.942017, 6919.056152, 34.28933, 2446542, 16, 60000)
end
function Master_Eaarthquake(pUnit, Event)
pUnit:FullCastSpellOnTarget(33919, pUnit:GetMainTank())
end
function Master_CharredEarth(pUnit, Event)
pUnit:FullCastSpellOnTarget(30129, pUnit:GetRandomPlayer(0))
end
function Master_Fnova(pUnit, Event)
pUnit:FullCastSpellOnTarget(31250, pUnit:GetMainTank())
end
function Master_Fboltvolley(pUnit, Event)
pUnit:FullCastSpellOnTarget(36741, pUnit:GetMainTank())
end
function Master_Frostarmor(pUnit, Event)
pUnit:CastSpell(12544, pUnit:GetClosestPlayer())
end
function Master_FlameBrath(pUnit, Event)
pUnit:FullCastSpellOnTarget(43140, pUnit:GetMainTank())
end
function Master_Soulburn(pUnit, Event)
pUnit:FullCastSpellOnTarget(19393, pUnit:GetRandomPlayer(0))
end
function Master_CharredEarth2(pUnit, Event)
pUnit:FullCastSpellOnTarget(30129, pUnit:GetRandomPlayer(0))
end
function Master_phaxe1(pUnit, Event)
if pUnit:GetHealthPct() < 85 then
pUnit:RemoveEvents();
pUnit:FullCastSpell(0)
pUnit:SetModel(14511)
pUnit:SendChatMessage(12, 0, "Earth! Protect me!")
pUnit:RegisterEvent("Earthele_Spawn",1,2)
pUnit:RegisterEvent("Master_Eaarthquake", 10000, 0)
pUnit:RegisterEvent("Master_CharredEarth", 15000, 0)
pUnit:RegisterEvent("Master_Phaxe2",1000,0)
end
end
function Master_Phaxe2(pUnit, Event)
if pUnit:GetHealthPct() < 60 then
pUnit:RemoveEvents();
pUnit:FullCastSpell(0)
pUnit:SetModel(525)
pUnit:SendChatMessage(12, 0, "Looks like you guys need to be a little bit cooler!")
pUnit:RegisterEvent("WaterEle_Spawn2",1,2)
pUnit:RegisterEvent("Master_Fnova", 30000, 0)
pUnit:RegisterEvent("Master_Fboltvolley", 15000, 0)
pUnit:RegisterEvent("Master_Frostarmor", 1, 1)
pUnit:RegisterEvent("Master_phaxe3",1000,0)
end
end
function Master_phaxe3(pUnit, Event)
if pUnit:GetHealthPct() < 30 then
pUnit:RemoveEvents();
pUnit:FullCastSpell(0)
pUnit:SetModel(1405)
pUnit:setScale(9.0)
pUnit:SendChatMessage(12, 0, "Enough with this shit! burn in hell!!")
pUnit:RegisterEvent("FireEle_Spawn3",1,2)
pUnit:RegisterEvent("Master_FlameBrath", 30000, 0)
pUnit:RegisterEvent("Master_Soulburn", 20000, 0)
pUnit:RegisterEvent("Master_CharredEarth2", 23000, 0)
end
end
function Master_OnLeaveCombat(Unit, Event)
Unit:RemoveEvents()
Unit:SetModel(21607)
Unit:SetScale(1.0)
end
function Master_OnDied(Unit, Event)
Unit:RemoveEvents()
Unit:SendChatMessage(11, 0, "I failed")
end
function Master_OnKilledTarget(Unit, Event)
Unit:SendChatMessage(11, 0, "Haha.. The elements got YOU!")
end
RegisterUnitEvent(909090, 1, "Master_OnCombat")
RegisterUnitEvent(909090, 2, "Master_OnLeaveCombat")
RegisterUnitEvent(909090, 3, "Master_OnKilledTarget")
RegisterUnitEvent(909090, 4, "Master_OnDied")
here is some pics