Auto Summoner w/auto healing by dennozz
#Auto-summoner ver.3.11
#********** INFORMATION **********#
#Made by @dennozz on discord.
#Inspired/learned by other scrips in https://outlands.uorazorscripts.com/
#This script will auto summon your desired followers and also auto heal you.
#********** SET YOUR SETTINGS **********#
@setvar! earthElementals 1
@setvar! waterElementals 1
@setvar! airElementals 0
@setvar! fireElementals 0
@setvar! summonDaemons 0
@setvar! summonCreature 1
#--- Set Necromancy Spells ---#
@setvar! NecroVengefulSpirit 0
@setvar! NecroBloodOath 0
@setvar! NecroWither 0
#--- Set mushrooms ---#
@setvar! mushroomCount 4
@setvar! mushroomTimerCD 60000
settimer mushroomTimer mushroomTimerCD
#--- Set meditation ---#
@setvar! useMeditation 1
@setvar! meditateManaReach 50
@setvar! meditateUntilManaReach 55
#--- Set Mage auto heals ---#
@setvar! miniHeal 1
@setvar! greaterHeal 1
@setvar! cureSpell 1
#--- Set Mage Buffs ---#
@setvar! magicReflect 1
@setvar! bless 1
@setvar! armorReflect 1
@setvar! protectionSpell 1
@setvar! miniumManaToBuff 50
#--- Set potions ---#
@setvar! drinkStr 1
@setvar! drinkAgility 0
@setvar! drinkMagicResist 0
@setvar! drinkHeal 1
@setvar! drinkCure 1
@setvar! drinkRefresh 1
@setvar! strengthLowerThan 100
@setvar! staminaLowerThan 10
#--- Auto healing hp diffs ---#
@setvar! lowDiff 12
@setvar! medDiff 25
@setvar! highDiff 40
@setvar! extremeDiff 60
@setvar! criticalDiff 75
#--- Optional : Have a cooldown named `Heal Pot` ---#
@setvar! healingPotCD 11000
@setvar! maxwaittimeinms 650
#********** DO NOT EDIT FROM HERE BELOW **********#
if not varexist castingEarth
@setvar! castingEarth 0
endif
if not varexist castingWater
@setvar! castingWater 0
endif
if not varexist castingFire
@setvar! castingFire 0
endif
if not varexist castingAir
@setvar! castingAir 0
endif
if not varexist castingDaemon
@setvar! castingDaemon 0
endif
if not varexist castingCreature
@setvar! castingCreature 0
endif
@setvar! necroGump 622436516
@setvar! unholyPoints 0
#-- elementals variables --#
@setvar! maxFollowers 0
@setvar! currentFollowers 0
removelist maxFollowersList
createlist maxFollowersList
if earthElementals = 1
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif earthElementals = 2
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
endif
if waterElementals = 1
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif waterElementals = 2
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
endif
if airElementals = 1
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif airElementals = 2
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
endif
if fireElementals = 1
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif fireElementals = 2
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
endif
if summonDaemons = 1
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif summonDaemons = 2
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
endif
if summonCreature = 1
pushlist maxFollowersList x
elseif summonCreature = 2
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif summonCreature = 3
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif summonCreature = 4
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
elseif summonCreature = 5
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
pushlist maxFollowersList x
endif
if list maxFollowersList = 0
@setvar! maxFollowers 0
elseif list maxFollowersList = 1
@setvar! maxFollowers 1
elseif list maxFollowersList = 2
@setvar! maxFollowers 2
elseif list maxFollowersList = 3
@setvar! maxFollowers 3
elseif list maxFollowersList = 4
@setvar! maxFollowers 4
else
@setvar! maxFollowers 5
endif
if not varexist earthFirsty or followers = 0
@setvar! earthFirsty 0
endif
if not varexist earthSecondly or followers = 0
@setvar! earthSecondly 0
endif
if not varexist waterFirsty or followers = 0
@setvar! waterFirsty 0
endif
if not varexist waterSecondly or followers = 0
@setvar! waterSecondly 0
endif
if not varexist airFirsty or followers = 0
@setvar! airFirsty 0
endif
if not varexist airSecondly or followers = 0
@setvar! airSecondly 0
endif
if not varexist fireFirsty or followers = 0
@setvar! fireFirsty 0
endif
if not varexist fireSecondly or followers = 0
@setvar! fireSecondly 0
endif
if not varexist daemonFirsty or followers = 0
@setvar! daemonFirsty 0
endif
if not varexist daemonSecondly or followers = 0
@setvar! daemonSecondly 0
endif
if not varexist creatureFirsty or followers = 0
@setvar! creatureFirsty 0
endif
if not varexist creatureSecondly or followers = 0
@setvar! creatureSecondly 0
endif
if not varexist creatureThirdy or followers = 0
@setvar! creatureThirdy 0
endif
if not varexist creatureFourthy or followers = 0
@setvar! creatureFourthy 0
endif
if not varexist creatureFithy or followers = 0
@setvar! creatureFithy 0
endif
#-- list creation --#
if not listexists earthListy or followers = 0
removelist earthListy
createlist earthListy
endif
if not listexists waterListy or followers = 0
removelist waterListy
createlist waterListy
endif
if not listexists airListy or followers = 0
removelist airListy
createlist airListy
endif
if not listexists fireListy or followers = 0
removelist fireListy
createlist fireListy
endif
if not listexists daemonListy or followers = 0
removelist daemonListy
createlist daemonListy
endif
if not listexists creatureListy or followers = 0
removelist creatureListy
createlist creatureListy
endif
@setvar! globalMessageCD 5000
settimer globalMessageTimer globalMessageCD
@setvar! summonMsgCD 1500
settimer summonMsgTimer summonMsgCD
@setvar! manaMsgCD 2500
settimer manaMsgTimer manaMsgCD
@setvar! guardMessageCD 5000
settimer guardMessageTimer guardMessageCD
#--- Script msgs timers ---#
@setvar! noRegsMessageCD 3000
settimer noRegsMessageTimer noRegsMessageCD
#--- Resources timers ---#
@setvar! pouchMessageCD 5000
settimer pouchMessageTimer pouchMessageCD
@setvar! aidsMessageCD 4000
settimer aidsMessageTimer aidsMessageCD
@setvar! whiteMessageCD 3000
settimer whiteMessageTimer whiteMessageCD
@setvar! blueMessageCD 3000
settimer blueMessageTimer blueMessageCD
@setvar! blackMessageCD 2500
settimer blackMessageTimer blackMessageCD
@setvar! orangeMessageCD 2000
settimer orangeMessageTimer orangeMessageCD
@setvar! yellowMessageCD 1500
settimer yellowMessageTimer yellowMessageCD
@setvar! redMessageCD 1000
settimer redMessageTimer redMessageCD
#--- Magery buffs timers ---#
@setvar! magicReflectCD 15000
settimer magicReflectTimer 15000
@setvar! armorReflectCD 15000
settimer armorReflectTimer 15000
@setvar! protectionCD 15000
settimer protectionTimer 15000
#sysmsg "MAX: {{maxFollowers}}" 34
while not dead
if timer globalMessageTimer > globalMessageCD
overhead "* Auto summoning *" 11
settimer globalMessageTimer 0
endif
#********* EAT TRAY FOOD *********
if not findbuff "food" and findtype "tray" backpack as fody
dclick fody
wait 200
endif
#********** AUTO HEALING START **********#
while diffhits >= lowDiff or paralyzed or poisoned
#sysmsg "auto-healing activated" 11
#--- Trapped ---#
if paralyzed
if findtype "pouch" backpack 38
yell "[pouch"
wait 200
else
if timer pouchMessageTimer > pouchMessageCD
overhead "Out of Pouches!" 34
settimer pouchMessageTimer 0
endif
endif
endif
#--- Self bandage ---#
if diffhits >= 1 and not bandaging
if skill 'healing' >= 50 or skill "veterinary" >= 50
if findtype 'clean bandage%s%' backpack
if targetexists
hotkey 'cancel current target'
endif
dclicktype 'clean bandage%s%'
waitfortarget maxwaittimeinms
target 'self'
wait 200
else
if timer aidsMessageTimer > aidsMessageCD
overhead "Out of bandages" 34
settimer aidsMessageTimer 0
endif
endif
endif
endif
#--- Drink str pot ---#
if drinkStr = 1 and str < strengthLowerThan
if not findbuff "Strength"
if findtype "White Potion" self
dclicktype "White Potion"
wait 200
else
if timer whiteMessageTimer > whiteMessageCD
overhead "Out of str pots" 34
settimer whiteMessageTimer 0
endif
endif
endif
endif
#--- Drink agility pot ---#
if drinkAgility = 1
if not findbuff "Agility"
if findtype "Blue Potion" self
dclicktype "Blue Potion"
wait 200
else
if timer blueMessageTimer > blueMessageCD
overhead "Out of agility pots" 34
settimer blueMessageTimer 0
endif
endif
endif
endif
#--- Drink magic resist pot ---#
if drinkMagicResist = 1
if not findbuff "Magic Resist"
if findtype "Black Potion" self
dclicktype "Black Potion"
wait 200
else
if timer blackMessageTimer > blackMessageCD
overhead "Out of resist pots" 34
settimer blackMessageTimer 0
endif
endif
endif
endif
#--- Poisoned ---#
if 1 = drinkCure or 1 = cureSpell
while poisoned
if findtype "Orange Potion" self
dclicktype "Orange Potion"
wait 200
else
if timer orangeMessageTimer > orangeMessageCD
overhead "Out of cure pots" 34
settimer orangeMessageTimer 0
endif
if diffhits > highDiff or not findtype 3972 self or not findtype 3973 self
break
endif
if skill 'magery' >= 40 and mana >= 6 and 1 = cureSpell and not casting
cast 'cure'
wait 50
while not casting
if targetexists
hotkey 'cancel current target'
endif
cast 'cure'
wait 50
endwhile
while not targetexists and casting
endwhile
waitfortarget maxwaittimeinms
target 'self'
wait 200
else
break
endif
endif
endwhile
endif
#--- Drink Heal Pot ---#
if diffhits >= highDiff and 1 = drinkHeal
if findtype "Yellow Potion" self as hPot
getlabel hPot potLabel
if "next" in potLabel
#do nothing
else
@setvar! ch 0
if counttype 3852 self as c
@setvar! ch c
endif
clearsysmsg
dclicktype 3852
getlabel backpack xxx
wait 200
if ch != counttype 3852 self or insysmsg "potion satchel used"
cooldown "Heal Pot" healingPotCD
endif
endif
else
if timer yellowMessageTimer > yellowMessageCD
overhead "Out of heals pots" 34
settimer yellowMessageTimer 0
endif
endif
endif
#--- Drink red pot ---#
if stam < staminaLowerThan and 1 = drinkRefresh
if findtype "Red Potion" self
dclicktype "Red Potion"
wait 200
else
if timer redMessageTimer > redMessageCD
overhead "Out of refresh pots" 34
settimer redMessageTimer 0
endif
endif
endif
#--- Cast heals ---#
if skill 'magery' >= 40 and diffhits >= lowDiff and diffhits < medDiff and mana >= 4 and miniHeal = 1 and not casting
cast 'heal'
while not casting
if targetexists
hotkey 'cancel current target'
endif
cast 'heal'
endwhile
while not targetexists and casting
endwhile
waitfortarget maxwaittimeinms
target 'self'
wait 200
elseif skill 'magery' >= 60 and diffhits >= medDiff and diffhits <= highDiff mana >= 11 and greaterHeal = 1 and not casting
cast 'greater heal'
while not casting
if targetexists
hotkey 'cancel current target'
endif
cast 'greater heal'
endwhile
while not targetexists and casting
#--- Poisoned ---#
if 1 = drinkCure
while poisoned
if findtype "Orange Potion" self
dclicktype "Orange Potion"
wait 200
else
if timer orangeMessageTimer > orangeMessageCD
overhead "Out of cure pots" 34
settimer orangeMessageTimer 0
break
endif
endif
endwhile
endif
#--- Drink Heal Pot ---#
if diffhits >= highDiff and 1 = drinkHeal
if findtype "Yellow Potion" self as hPot
getlabel hPot potLabel
if "next" in potLabel
#do nothing
else
@setvar! ch 0
if counttype 3852 self as c
@setvar! ch c
endif
clearsysmsg
dclicktype 3852
getlabel backpack xxx
wait 200
if ch != counttype 3852 self or insysmsg "potion satchel used"
cooldown "Heal Pot" healingPotCD
endif
endif
else
if timer yellowMessageTimer > yellowMessageCD
overhead "Out of heals pots" 34
settimer yellowMessageTimer 0
endif
endif
endif
endwhile
waitfortarget maxwaittimeinms
target 'self'
wait 200
elseif skill 'magery' >= 40 and diffhits > highDiff and mana >= 4 and miniHeal = 1 and not casting
cast 'heal'
while not casting
if targetexists
hotkey 'cancel current target'
endif
cast 'heal'
endwhile
while not targetexists and casting
endwhile
waitfortarget maxwaittimeinms
target 'self'
wait 200
endif
endwhile
#********** CHECK FOR ANY DEAD ELEMENTAL **********#
while followers < maxFollowers and diffhits < medDiff
if counttype 29012 backpack = 0
while counttype 29012 backpack < mushroomCount
cast 'create food'
wait 100
endwhile
endif
if 1 = castingEarth
sysmsg "fixing earth" 44
while findtype 158|14 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != earthFirsty and ele != earthSecondly
hotkey 'cancel current target'
if earthFirsty = 0
@setvar! earthFirsty ele
sysmsg "add earth 1" 11
overhead "Earth 1" 634 ele
else
@setvar! earthSecondly ele
sysmsg "add earth 2" 11
overhead "Earth 2" 634 ele
endif
break
endif
endif
@ignore ele
endwhile
@clearignore
@setvar! castingEarth 0
elseif 1 = castingWater
sysmsg "fixing water" 44
while findtype 740|16 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != waterFirsty and ele != waterSecondly
hotkey 'cancel current target'
if waterFirsty = 0
@setvar! waterFirsty ele
sysmsg "add water 1" 11
overhead "Water 1" 399 ele
else
@setvar! waterSecondly ele
sysmsg "add water 2" 11
overhead "Water 2" 399 ele
endif
break
endif
endif
@ignore ele
endwhile
@clearignore
@setvar! castingWater 0
elseif 1 = castingAir
while findtype 306|13 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != airFirsty and ele != airSecondly
hotkey 'cancel current target'
if airFirsty = 0
@setvar! airFirsty ele
sysmsg "add air 1" 11
overhead "Air 1" 933 ele
else
@setvar! airSecondly ele
sysmsg "add air 2" 11
overhead "Air 2" 933 ele
endif
break
endif
endif
@ignore ele
endwhile
@clearignore
@setvar! castingAir 0
elseif 1 = castingFire
while findtype 24|15 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != fireFirsty and ele != fireSecondly
hotkey 'cancel current target'
if fireFirsty = 0
@setvar! fireFirsty ele
sysmsg "add fire 1" 11
overhead "Fire 1" 353 ele
else
@setvar! fireSecondly ele
sysmsg "add fire 2" 11
overhead "Fire 2" 353 ele
endif
break
endif
endif
@ignore ele
endwhile
@clearignore
@setvar! castingFire 0
elseif 1 = castingDaemon
while findtype 9|722 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != daemonFirsty and ele != daemonSecondly
hotkey 'cancel current target'
if daemonFirsty = 0
@setvar! daemonFirsty ele
sysmsg "add daemon 1" 11
overhead "Daemon 1" 11 ele
else
@setvar! daemonSecondly ele
sysmsg "add daemon 2" 235
overhead "Daemon 2" 235 ele
endif
break
endif
endif
@ignore ele
endwhile
@clearignore
@setvar! castingDaemon 0
elseif 1 = castingCreature
while findtype 215|211|302|317|225|212|202|213|716|729|51|74|214|206|776|737|718|739|718|29|776|317|302|39|56|26|3|57|50|382 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != creatureFirsty and ele != creatureSecondly and ele != creatureThirdy and ele != creatureFourthy and ele != creatureFithy
hotkey 'cancel current target'
if creatureFirsty = 0
@setvar! creatureFirsty ele
sysmsg "Creature 1" 11
overhead "Creature 1" 11 ele
elseif creatureSecondly = 0
@setvar! creatureSecondly ele
sysmsg "add creature 2" 11
overhead "Creature 2" 11 ele
elseif creatureThirdy = 0
@setvar! creatureThirdy ele
sysmsg "add creature 3" 11
overhead "Creature 3" 11 ele
elseif creatureFourthy = 0
@setvar! creatureFourthy ele
sysmsg "add creature 4" 11
overhead "Creature 4" 11 ele
elseif creatureFithy = 0
@setvar! creatureFithy ele
sysmsg "add creature 5" 11
overhead "Creature 5" 11 ele
endif
break
endif
endif
@ignore ele
endwhile
@clearignore
@setvar! castingCreature 0
endif
if earthFirsty != 0 and dead earthFirsty
if list earthListy != 0
poplist earthListy 'front'
sysmsg "pop earth 1"
endif
@setvar! earthFirsty 0
endif
if earthSecondly != 0 and dead earthSecondly
if list earthListy != 0
poplist earthListy 'front'
sysmsg "pop earth 2"
endif
@setvar! earthSecondly 0
endif
if waterFirsty != 0 and dead waterFirsty
if list waterListy != 0
poplist waterListy 'front'
sysmsg "pop water 1"
endif
@setvar! waterFirsty 0
endif
if waterSecondly != 0 and dead waterSecondly
if list waterListy != 0
poplist waterListy 'front'
sysmsg "pop water 2"
endif
@setvar! waterSecondly 0
endif
if airFirsty != 0 and dead airFirsty
if list airListy != 0
poplist airListy 'front'
endif
@setvar! airFirsty 0
endif
if airSecondly != 0 and dead airSecondly
if list airListy != 0
poplist airListy 'front'
endif
@setvar! airSecondly 0
endif
if fireFirsty != 0 and dead fireFirsty
if list fireListy != 0
poplist fireListy 'front'
endif
@setvar! fireFirsty 0
endif
if fireSecondly != 0 and dead fireSecondly
if list fireListy != 0
poplist fireListy 'front'
endif
@setvar! fireSecondly 0
endif
if daemonFirsty != 0 and dead daemonFirsty
if list daemonListy != 0
poplist daemonListy 'front'
endif
@setvar! daemonFirsty 0
endif
if daemonSecondly != 0 and dead daemonSecondly
if list daemonListy != 0
poplist daemonListy 'front'
endif
@setvar! daemonSecondly 0
endif
if creatureFirsty != 0 and dead creatureFirsty
if list creatureListy != 0
poplist creatureListy 'front'
sysmsg "pop creature 1"
endif
@setvar! creatureFirsty 0
endif
if creatureSecondly != 0 and dead creatureSecondly
if list creatureListy != 0
poplist creatureListy 'front'
sysmsg "pop creature 2"
endif
@setvar! creatureSecondly 0
endif
if creatureThirdy != 0 and dead creatureThirdy
if list creatureListy != 0
poplist creatureListy 'front'
sysmsg "pop creature 3"
endif
@setvar! creatureThirdy 0
endif
if creatureFourthy != 0 and dead creatureFourthy
if list creatureListy != 0
poplist creatureListy 'front'
sysmsg "pop creature 4"
endif
@setvar! creatureFourthy 0
endif
if creatureFithy != 0 and dead creatureFithy
if list creatureListy != 0
poplist creatureListy 'front'
sysmsg "pop creature 5"
endif
@setvar! creatureFithy 0
endif
#********* CREATE MUSHROOMS *********
if mana <= 50
if timer mushroomTimer > mushroomTimerCD
if counttype 29012 backpack as c
@setvar! cm c
dclicktype 29012 backpack
wait 200
if cm != counttype 29012 backpack
settimer mushroomTimer 0
endif
else
overhead "No mushrooms found!" 34
endif
endif
endif
if mana < meditateManaReach and 1 = useMeditation
skill 'meditation'
getlabel backpack xxx
wait 200
if findbuff 'meditating'
while mana < meditateUntilManaReach and diffhits < medDiff
#interrupt here if hp is low
if not findbuff 'meditating'
break
endif
endwhile
endif
endif
if mana < 50
if timer manaMsgTimer > manaMsgCD
overhead "No mana to summon" 34
settimer manaMsgTimer 0
endif
break
endif
@clearsysmsg
@setvar! wasInterrupted 0
#********** ACTIVATE NECROMANCER BAR IF USING ANY NECRO SPELLS **********#
if NecroVengefulSpirit = 1 or NecroBloodOath = 1
if findtype 'necromancer book' backpack
yell '[necromancyhotbar'
while not gumpexists 622436516
yell '[necromancyhotbar'
waitforgump 622436516 maxwaittimeinms
endwhile
endif
endif
#********** ACTIVATE NECROMANCER VENGEFUL SPIRIT SPELL **********#
if ingump "20/" 622436516
@setvar! unholyPoints 20
elseif ingump "19/" 622436516
@setvar! unholyPoints 19
elseif ingump "18/" 622436516
@setvar! unholyPoints 18
elseif ingump "17/" 622436516
@setvar! unholyPoints 17
elseif ingump "16/" 622436516
@setvar! unholyPoints 16
elseif ingump "15/" 622436516
@setvar! unholyPoints 15
elseif ingump "14/" 622436516
@setvar! unholyPoints 14
elseif ingump "13/" 622436516
@setvar! unholyPoints 13
elseif ingump "12/" 622436516
@setvar! unholyPoints 12
elseif ingump "11/" 622436516
@setvar! unholyPoints 11
elseif ingump "10/" 622436516
@setvar! unholyPoints 10
elseif ingump "9/" 622436516
@setvar! unholyPoints 9
elseif ingump "8/" 622436516
@setvar! unholyPoints 8
elseif ingump "7/" 622436516
@setvar! unholyPoints 7
elseif ingump "6/" 622436516
@setvar! unholyPoints 6
elseif ingump "5/" 622436516
@setvar! unholyPoints 5
elseif ingump "4/" 622436516
@setvar! unholyPoints 4
elseif ingump "3/" 622436516
@setvar! unholyPoints 3
elseif ingump "2/" 622436516
@setvar! unholyPoints 2
elseif ingump "1/" 622436516
@setvar! unholyPoints 1
else
@setvar unholyPoints 0
endif
if 1 = NecroVengefulSpirit and 0 < unholyPoints
clearsysmsg
yell '[vengefulspirit'
wait 200
while not insysmsg! "unholy symbols remaining" and not insysmsg! "you must wait another"
yell '[vengefulspirit'
wait 200
endwhile
if insysmsg "unholy symbols"
say '[>Vengeful Spirits<]' 44
endif
endif
#********** ACTIVATE NECROMANCER BLOOD OATH SPELL **********#
if ingump "20/" 622436516
@setvar! unholyPoints 20
elseif ingump "19/" 622436516
@setvar! unholyPoints 19
elseif ingump "18/" 622436516
@setvar! unholyPoints 18
elseif ingump "17/" 622436516
@setvar! unholyPoints 17
elseif ingump "16/" 622436516
@setvar! unholyPoints 16
elseif ingump "15/" 622436516
@setvar! unholyPoints 15
elseif ingump "14/" 622436516
@setvar! unholyPoints 14
elseif ingump "13/" 622436516
@setvar! unholyPoints 13
elseif ingump "12/" 622436516
@setvar! unholyPoints 12
elseif ingump "11/" 622436516
@setvar! unholyPoints 11
elseif ingump "10/" 622436516
@setvar! unholyPoints 10
elseif ingump "9/" 622436516
@setvar! unholyPoints 9
elseif ingump "8/" 622436516
@setvar! unholyPoints 8
elseif ingump "7/" 622436516
@setvar! unholyPoints 7
elseif ingump "6/" 622436516
@setvar! unholyPoints 6
elseif ingump "5/" 622436516
@setvar! unholyPoints 5
elseif ingump "4/" 622436516
@setvar! unholyPoints 4
elseif ingump "3/" 622436516
@setvar! unholyPoints 3
elseif ingump "2/" 622436516
@setvar! unholyPoints 2
elseif ingump "1/" 622436516
@setvar! unholyPoints 1
else
@setvar unholyPoints 0
endif
if 1 = NecroBloodOath and 3 < unholyPoints
clearsysmsg
yell '[bloodoath'
wait 200
while not insysmsg! "unholy symbols remaining" and not insysmsg! "you must wait another"
yell '[bloodoath'
wait 200
endwhile
if insysmsg "unholy symbols"
say '[>Blood Oath<]' 55
endif
endif
#********** ACTIVATE NECROMANCER WITHER SPELL **********#
if ingump "20/" 622436516
@setvar! unholyPoints 20
elseif ingump "19/" 622436516
@setvar! unholyPoints 19
elseif ingump "18/" 622436516
@setvar! unholyPoints 18
elseif ingump "17/" 622436516
@setvar! unholyPoints 17
elseif ingump "16/" 622436516
@setvar! unholyPoints 16
elseif ingump "15/" 622436516
@setvar! unholyPoints 15
elseif ingump "14/" 622436516
@setvar! unholyPoints 14
elseif ingump "13/" 622436516
@setvar! unholyPoints 13
elseif ingump "12/" 622436516
@setvar! unholyPoints 12
elseif ingump "11/" 622436516
@setvar! unholyPoints 11
elseif ingump "10/" 622436516
@setvar! unholyPoints 10
elseif ingump "9/" 622436516
@setvar! unholyPoints 9
elseif ingump "8/" 622436516
@setvar! unholyPoints 8
elseif ingump "7/" 622436516
@setvar! unholyPoints 7
elseif ingump "6/" 622436516
@setvar! unholyPoints 6
elseif ingump "5/" 622436516
@setvar! unholyPoints 5
elseif ingump "4/" 622436516
@setvar! unholyPoints 4
elseif ingump "3/" 622436516
@setvar! unholyPoints 3
elseif ingump "2/" 622436516
@setvar! unholyPoints 2
elseif ingump "1/" 622436516
@setvar! unholyPoints 1
else
@setvar unholyPoints 0
endif
if 1 = NecroWither and 4 < unholyPoints and skill 'necromancy' >= 90
clearsysmsg
yell '[wither'
wait 200
while not insysmsg! "unholy symbols remaining" and not insysmsg! "you must wait another"
yell '[wither'
wait 200
endwhile
if insysmsg "unholy symbols"
say '[>Wither<]' 66
endif
endif
if list earthListy = 0
#sysmsg "Earth List = 0"
elseif list earthListy = 1
#sysmsg "Earth List = 1"
elseif list earthListy = 2
#sysmsg "Earth List = 2"
endif
if list waterListy = 0
#sysmsg "Water List = 0"
elseif list waterListy = 1
#sysmsg "Water List = 1"
elseif list waterListy = 2
#sysmsg "Water List = 2"
endif
if list creatureListy = 0
#sysmsg "Creature List = 0"
elseif list creatureListy = 1
#sysmsg "Creature List = 1"
elseif list creatureListy = 2
#sysmsg "Creature List = 2"
elseif list creatureListy = 2
#sysmsg "Creature List = 2"
elseif list creatureListy = 2
#sysmsg "Creature List = 2"
endif
sysmsg 'begin casting elementals...' 11
if not findtype 3963 backpack or not findtype 3974 backpack or not findtype 3981 backpack
if timer noRegsMessageTimer > noRegsMessageCD
overhead 'Out of regs!' 34
settimer noRegsMessageTimer 0
endif
elseif fireElementals = 1 and not findtype 3980 backpack
if timer noRegsMessageTimer > noRegsMessageCD
overhead 'Out of regs!' 34
settimer noRegsMessageTimer 0
endif
elseif summonDaemons = 1 and not findtype 3980 backpack
if timer noRegsMessageTimer > noRegsMessageCD
overhead 'Out of regs!' 34
settimer noRegsMessageTimer 0
endif
#********** CAST EARTH ELEMENTAL **********#
elseif earthElementals != 0 and list earthListy < earthElementals and followers < 4 and diffhits < medDiff and not casting
cast 'Earth Elemental'
@setvar! castingEarth 1
while not casting
cast 'Earth Elemental'
if targetexists
hotkey 'cancel current target'
endif
endwhile
while not dead
if diffhits >= medDiff
@setvar! wasInterrupted 1
sysmsg "interrupted low health" 33
interrupt
break
endif
if not casting
getlabel backpack xxx
wait 200
if insysmsg "Your concentration"
@setvar! wasInterrupted 1
sysmsg "interrupted concentration" 33
else
sysmsg "casting finished" 11
endif
break
endif
if timer summonMsgTimer > summonMsgCD
overhead "* summoning earth... *" 634
sysmsg "* summoning earth... *" 634
settimer summonMsgTimer 0
settimer globalMessageTimer 0
endif
endwhile
if 0 = wasInterrupted
sysmsg "Summon Earth Successful"
pushlist earthListy 'x' 'front'
while not dead
if findtype 158|14 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != earthFirsty and ele != earthSecondly
hotkey 'cancel current target'
if earthFirsty = 0
@setvar! earthFirsty ele
sysmsg "add earth 1" 11
overhead "Earth 1" 634 ele
else
@setvar! earthSecondly ele
sysmsg "add earth 2" 11
overhead "Earth 2" 634 ele
endif
break
endif
endif
@ignore ele
endif
endwhile
@clearignore
@setvar! castingEarth 0
endif
#********** CAST WATER ELEMENTAL **********#
elseif waterElementals != 0 and list waterListy < waterElementals and followers < 4 and diffhits < medDiff and not casting
cast 'Water Elemental'
@setvar! castingWater 1
while not casting
cast 'Water Elemental'
if targetexists
hotkey 'cancel current target'
endif
endwhile
while not dead
if diffhits >= medDiff
@setvar! wasInterrupted 1
sysmsg "interrupted low health" 33
interrupt
break
endif
if not casting
getlabel backpack xxx
wait 200
if insysmsg "Your concentration"
@setvar! wasInterrupted 1
sysmsg "interrupted concentration" 33
else
sysmsg "casting finished" 11
endif
break
endif
if timer summonMsgTimer > summonMsgCD
overhead "* summoning water... *" 399
sysmsg "* summoning water... *" 399
settimer summonMsgTimer 0
settimer globalMessageTimer 0
endif
endwhile
if 0 = wasInterrupted
sysmsg "Summon Water Successful"
pushlist waterListy 'x' 'front'
while not dead
if findtype 740|16 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != waterFirsty and ele != waterSecondly
hotkey 'cancel current target'
if waterFirsty = 0
@setvar! waterFirsty ele
sysmsg "add water 1" 11
overhead "Water 1" 399 ele
else
@setvar! waterSecondly ele
sysmsg "add water 2" 11
overhead "Water 2" 399 ele
endif
break
endif
endif
@ignore ele
endif
endwhile
@clearignore
@setvar! castingWater 0
endif
#********** CAST AIR ELEMENTAL **********#
elseif airElementals != 0 and list airListy < airElementals and followers < 4 and diffhits < medDiff and not casting
cast 'Air Elemental'
@setvar! castingAir 1
while not casting
cast 'Air Elemental'
if targetexists
hotkey 'cancel current target'
endif
endwhile
while not dead
if diffhits >= medDiff
@setvar! wasInterrupted 1
sysmsg "interrupted low health" 33
interrupt
break
endif
if not casting
getlabel backpack xxx
wait 200
if insysmsg "Your concentration"
@setvar! wasInterrupted 1
sysmsg "interrupted concentration" 33
else
sysmsg "casting finished" 11
endif
break
endif
if timer summonMsgTimer > summonMsgCD
overhead "* summoning air... *" 933
sysmsg "* summoning air... *" 933
settimer summonMsgTimer 0
settimer globalMessageTimer 0
endif
endwhile
if 0 = wasInterrupted
sysmsg "Summon Air Successful"
pushlist airListy 'x' 'front'
while not dead
if findtype 306|13 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != airFirsty and ele != airSecondly
hotkey 'cancel current target'
if airFirsty = 0
@setvar! airFirsty ele
sysmsg "add air 1" 11
overhead "Air 1" 933 ele
else
@setvar! airSecondly ele
sysmsg "add air 2" 11
overhead "Air 2" 933 ele
endif
break
endif
endif
@ignore ele
endif
endwhile
@clearignore
@setvar! castingAir 0
endif
#********** CAST FIRE ELEMENTAL **********#
elseif fireElementals != 0 and list fireListy < fireElementals and followers < 4 and diffhits < medDiff and not casting
cast 'Fire Elemental'
@setvar! castingFire 1
while not casting
cast 'Fire Elemental'
if targetexists
hotkey 'cancel current target'
endif
endwhile
while not dead
if diffhits >= medDiff
@setvar! wasInterrupted 1
sysmsg "interrupted low health" 33
interrupt
break
endif
if not casting
getlabel backpack xxx
wait 200
if insysmsg "Your concentration"
@setvar! wasInterrupted 1
sysmsg "interrupted concentration" 33
else
sysmsg "casting finished" 11
endif
break
endif
if timer summonMsgTimer > summonMsgCD
overhead "* summoning fire... *" 353
sysmsg "* summoning fire... *" 353
settimer summonMsgTimer 0
settimer globalMessageTimer 0
endif
endwhile
if 0 = wasInterrupted
sysmsg "Summon Fire Successful"
pushlist fireListy 'x' 'front'
while not dead
if findtype 24|15 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != fireFirsty and ele != fireSecondly
hotkey 'cancel current target'
if fireFirsty = 0
@setvar! fireFirsty ele
sysmsg "add fire 1" 11
overhead "Fire 1" 353 ele
else
@setvar! fireSecondly ele
sysmsg "add fire 2" 11
overhead "Fire 2" 353 ele
endif
break
endif
endif
@ignore ele
endif
endwhile
@clearignore
@setvar! castingFire 0
endif
#********** CAST DAEMON **********#
elseif summonDaemons != 0 and list daemonListy < summonDaemons and followers < 4 and diffhits < medDiff and not casting
cast 'Summon Daemon'
@setvar! castingDaemon 1
while not casting
cast 'Summon Daemon'
if targetexists
hotkey 'cancel current target'
endif
endwhile
while not dead
if diffhits >= medDiff
@setvar! wasInterrupted 1
sysmsg "interrupted low health" 33
interrupt
break
endif
if not casting
getlabel backpack xxx
wait 200
if insysmsg "Your concentration"
@setvar! wasInterrupted 1
sysmsg "interrupted concentration" 33
else
sysmsg "casting finished" 11
endif
break
endif
if timer summonMsgTimer > summonMsgCD
overhead "* summoning daemon... *" 235
sysmsg "* summoning daemon... *" 235
settimer summonMsgTimer 0
settimer globalMessageTimer 0
endif
endwhile
if 0 = wasInterrupted
sysmsg "Summon Daemon Successful"
pushlist daemonListy 'x' 'front'
while not dead
if findtype 9|722 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != daemonFirsty and ele != daemonSecondly
hotkey 'cancel current target'
if daemonFirsty = 0
@setvar! daemonFirsty ele
sysmsg "add daemon 1" 11
overhead "Daemon 1" 11 ele
else
@setvar! daemonSecondly ele
sysmsg "add daemon 2" 235
overhead "Daemon 2" 235 ele
endif
break
endif
endif
@ignore ele
endif
endwhile
@clearignore
@setvar! castingDaemon 0
endif
#********** CAST SUMMON CREATURE **********#
elseif summonCreature != 0 and list creatureListy < summonCreature and followers < 5 and diffhits < medDiff and not casting
cast 'Summ. Creature'
@setvar! castingCreature 1
while not casting
cast 'Summ. Creature'
if targetexists
hotkey 'cancel current target'
endif
endwhile
while not dead
if diffhits >= medDiff
@setvar! wasInterrupted 1
sysmsg "interrupted low health" 33
interrupt
break
endif
if not casting
getlabel backpack xxx
wait 200
if insysmsg "Your concentration"
@setvar! wasInterrupted 1
sysmsg "interrupted concentration" 33
else
sysmsg "casting finished" 11
endif
break
endif
if timer summonMsgTimer > summonMsgCD
overhead "* summon creature... *" 881
sysmsg "* summon creature... *" 881
settimer summonMsgTimer 0
settimer globalMessageTimer 0
endif
endwhile
if 0 = wasInterrupted
sysmsg "Summon Creature Successful"
pushlist creatureListy 'x' 'front'
while not dead
if findtype 215|211|302|317|225|212|202|213|716|729|51|74|214|206|776|737|718|739|718|29|776|317|302|39|56|26|3|57|50|382 ground -1 -1 12 as ele
menu ele 1
waitfortarget maxwaittimeinms
if targetexists
if ele != creatureFirsty and ele != creatureSecondly and ele != creatureThirdy and ele != creatureFourthy and ele != creatureFithy
hotkey 'cancel current target'
if creatureFirsty = 0
@setvar! creatureFirsty ele
sysmsg "add creature 1" 11
overhead "Creature 1" 11 ele
elseif creatureSecondly = 0
@setvar! creatureSecondly ele
sysmsg "add creature 2" 11
overhead "Creature 2" 11 ele
elseif creatureThirdy = 0
@setvar! creatureThirdy ele
sysmsg "add creature 3" 11
overhead "Creature 3" 11 ele
elseif creatureFourthy = 0
@setvar! creatureFourthy ele
sysmsg "add creature 4" 11
overhead "Creature 4" 11 ele
elseif creatureFithy = 0
@setvar! creatureFithy ele
sysmsg "add creature 5" 11
overhead "Creature 5" 11 ele
endif
break
endif
endif
@ignore ele
endif
endwhile
@clearignore
@setvar! castingCreature 0
endif
endif
if followers > 0
say 'ALL Guard ME' 11
endif
endwhile
#********** AUTO-MAGERY BUFFS IF NEEDED **********
if magicReflect = 1 and skill 'magery' >= 70 and not findbuff "Magic Reflection" and mana >= miniumManaToBuff and diffhits < lowDiff
if timer magicReflectTimer > magicReflectCD
cast 'Magic Reflection'
while not casting and diffhits < lowDiff
getlabel backpack xxx
wait 200
if insysmsg "that spell will not" or insysmsg "that spell is already"
settimer magicReflectTimer 0
break
endif
if targetexists
hotkey 'cancel current target'
endif
cast 'Magic Reflection'
endwhile
while casting and diffhits < highDiff
#--- Poisoned ---#
if 1 = drinkCure
while poisoned
if findtype "Orange Potion" self
dclicktype "Orange Potion"
wait 200
else
if timer orangeMessageTimer > orangeMessageCD
overhead "Out of cure pots" 34
settimer orangeMessageTimer 0
break
endif
endif
endwhile
endif
#--- Drink Heal Pot ---#
if diffhits >= highDiff and 1 = drinkHeal
if findtype "Yellow Potion" self as hPot
getlabel hPot potLabel
if "next" in potLabel
#do nothing
else
@setvar! ch 0
if counttype 3852 self as c
@setvar! ch c
endif
clearsysmsg
dclicktype 3852
getlabel backpack xxx
wait 200
if ch != counttype 3852 self or insysmsg "potion satchel used"
cooldown "Heal Pot" healingPotCD
endif
endif
else
if timer yellowMessageTimer > yellowMessageCD
overhead "Out of heals pots" 34
settimer yellowMessageTimer 0
endif
endif
endif
endwhile
wait 200
endif
endif
if armorReflect = 1 and skill 'magery' >= 30 and not findbuff "Reactive Armor" and mana >= miniumManaToBuff and diffhits < lowDiff
if timer magicReflectTimer > magicReflectCD
cast 'Reactive Armor'
while not casting and diffhits < highDiff
getlabel backpack xxx
wait 200
if insysmsg "that spell will not" or insysmsg "that spell is already"
settimer armorReflectTimer 0
break
endif
if targetexists
hotkey 'cancel current target'
endif
cast 'Reactive Armor'
endwhile
while casting and diffhits < lowDiff
endwhile
wait 200
endif
endif
if protectionSpell = 1 and skill 'magery' >= 40 and not findbuff "Protection" and mana >= miniumManaToBuff and diffhits < lowDiff
cast 'Protection'
while not casting and diffhits < highDiff
if targetexists
hotkey 'cancel current target'
endif
cast 'Protection'
endwhile
while casting and diffhits < lowDiff
endwhile
wait 200
endif
if bless = 1 and skill 'magery' >= 50 and not findbuff "Cunning" and mana >= miniumManaToBuff and diffhits < lowDiff
sysmsg 'blessing..'
cast 'Bless'
while not casting and diffhits < highDiff
if targetexists
hotkey 'cancel current target'
endif
cast 'Bless'
wait 50
endwhile
while not targetexists and casting
endwhile
waitfortarget maxwaittimeinms
target 'self'
wait 200
endif
endwhile