jaseowns Auto Necro Summoner flexibility edit by Hayes
Related: Magery
Description: Edited version of jaseown's auto necro script, fixed spelling errors, added mode to alternate between mind blast/flamestrike, to cover most pve situations.
Can ignore this for now, looks like jase added the mind blast/flamestrike interactions to his main script.
1# One hotkey mage cycle, nox, poison by Jaseowns
2# UO Outlands - https://youtu.be/K3bVPhHcInE
3#
4# Cooldowns are live, so this script now attempts to display those
5# Make cooldowns match the names of skills
6# (check out for details: https://youtu.be/s8rRk2Bu1jQ)
7#
8// 12/11/2022
9// - Added Necro symbol count and additional necro spells (blood oath, pain spike)
10// - Added cast triggers for all the spells
11// - Added Necro wither to summon (if correct necro skill)
12// 12/10/2022
13// - If you kill a mob and are low mana, we now target the next one and send the pets while med
14// 12/9/2022
15// - Added discordance checks
16// - Added mushroom usage throughout the script
17// - Better summoning of pets when they die
18// - Added customized spam cooldown to prevent overhead spam
19// - Make sure herding goes off
20// November
21// - Add heal to top of script during search of target
22// - made a way to skip certain casts
23//
24##################
25## Always room for improvment, thanks for watching!
26############
27
28# Set this to one, if you want to cast poison once no matter what
29# If you have 100 poisoning and want Lethal, set this to 0
30@setvar! castPoisonAnyway 0
31
32# We will spam mind blast when other skills are on cooldown
33# If you set this to 0 it will use flamestrike
34# If you set this to 1 it will use mind blast
35# If you set this to 2 it will alternate between the two
36@setvar! spamMindBlastOverFlamestrike 2
37
38# This will auto replay this script if you want it too
39@setvar! autoBotEnabled 1
40
41# Update this variable to 1 for ALL KILL
42# Update this variable to 0 for target nearest
43@setvar! setThisAsOneIfYouWantToTargetYourOwnKillOrItWillTargetClosestMonster 0
44
45###############
46### Choose your spells
47######
48@setvar! castCurse 1
49@setvar! castManadrain 1
50@setvar! castLightning 1
51@setvar! castFireball 1
52@setvar! castHarm 1
53@setvar! castMagicArrow 1
54
55### Buffs
56@setvar! castBless 1
57@setvar! castMagicShield 1
58@setvar! castReactiveArmor 1
59# Drink Magic resist potion (only if magic shield buff not found)
60@setvar! drinkMagicResistPot 1
61
62###############
63### Choose your necro spells (ignored if less then required necro skill)
64######
65@setvar! castEvilOmen 1
66@setvar! castCorpseSkin 1
67@setvar! castVampiricEmbrace 1
68@setvar! castMindRot 0
69@setvar! castBloodOath 0
70@setvar! castPainSpike 0
71
72###############
73### Edit these cooldowns to match your wizard grimoire
74######
75@setvar! canYouMakeAMushroom 1
76@setvar! cdLightning 20000
77@setvar! cdMagicArrow 20000
78@setvar! cdHarm 20000
79@setvar! cdFireball 20000
80
81###############
82### Necro Cooldowns
83######
84@setvar! cdEvilOmen 31000
85@setvar! cdVampiricEmbrace 31000
86@setvar! cdCorpseSkin 31000
87@setvar! cdMindRot 31000
88@setvar! cdWither 31000
89@setvar! cdVengefulSpirit 31000
90@setvar! cdBloodOath 31000
91@setvar! cdPainSpike 61000
92
93#### Buff Cooldowns
94@setvar! cdMushroom 60000
95@setvar! cdMagicShield 60000
96@setvar! cdReactiveArmor 60000
97@setvar! cdMeditation 10000
98@setvar! cdMeditationMini 3000
99@setvar! cdKillTarget 60000
100
101#### Random cooldowns
102@setvar! cdPreventOverheadSpam 2000
103
104#### Pet Names, unique to you
105if not listexists petNameList
106 createlist petNameList
107endif
108if list petNameList = 0
109 pushlist petNameList "BeyondSausage"
110 pushlist petNameList "CageFreeHens"
111 pushlist petNameList "InstantPotUltra"
112 pushlist petNameList "AirFryerLid"
113 pushlist petNameList "KingArthurFlour"
114 pushlist petNameList "BisquickBaking"
115endif
116
117##################################################################
118#
119# Hopefully you do not have to edit after this :)
120#
121##################################################################
122
123if not gumpexists 622436516 and skill "Necromancy" >= 50
124 say '[NecromancyHotbar'
125 wait 500
126endif
127
128// Make sure we have a spell book attached
129if findlayer self righthand as item
130 // do nothing
131elseif findtype "3834" backpack as item
132 dclick item
133else
134 overhead "Spellbook not found" 34
135endif
136
137// Setting current necro symbols - checks again it the attack loop
138@setvar! necroSymbols 12
139if gumpexists 622436516 and skill "Necromancy" >= 50
140 if ingump "12/" 622436516
141 @setvar! necroSymbols 12
142 elseif ingump "11/" 622436516
143 @setvar! necroSymbols 11
144 elseif ingump "10/" 622436516
145 @setvar! necroSymbols 10
146 elseif ingump "9/" 622436516
147 @setvar! necroSymbols 9
148 elseif ingump "8/" 622436516
149 @setvar! necroSymbols 8
150 elseif ingump "7/" 622436516
151 @setvar! necroSymbols 7
152 elseif ingump "6/" 622436516
153 @setvar! necroSymbols 6
154 elseif ingump "5/" 622436516
155 @setvar! necroSymbols 5
156 elseif ingump "4/" 622436516
157 @setvar! necroSymbols 4
158 elseif ingump "3/" 622436516
159 @setvar! necroSymbols 3
160 elseif ingump "2/" 622436516
161 @setvar! necroSymbols 2
162 elseif ingump "1/" 622436516
163 @setvar! necroSymbols 1
164 elseif ingump "0/" 622436516
165 @setvar! necroSymbols 0
166 endif
167endif
168
169if not timerexists reactiveArmorTimer
170 createtimer reactiveArmorTimer
171 settimer reactiveArmorTimer cdMagicShield
172endif
173
174if not timerexists magicShieldTimer
175 createtimer magicShieldTimer
176 settimer magicShieldTimer cdMagicShield
177endif
178
179if not timerexists magicMushroomTimer
180 createtimer magicMushroomTimer
181 settimer magicMushroomTimer cdMushroom
182endif
183
184if not timerexists magicArrowTimer
185 createtimer magicArrowTimer
186 settimer magicArrowTimer cdMagicArrow
187endif
188
189if not timerexists lightningTimer
190 createtimer lightningTimer
191 settimer lightningTimer cdLightning
192endif
193
194if not timerexists harmTimer
195 createtimer harmTimer
196 settimer harmTimer cdHarm
197endif
198
199if not timerexists fireballTimer
200 createtimer fireballTimer
201 settimer fireballTimer cdFireball
202endif
203
204if not timerexists evilOmenTimer
205 createtimer evilOmenTimer
206 settimer evilOmenTimer cdEvilOmen
207endif
208
209if not timerexists vampiricEmbraceTimer
210 createtimer vampiricEmbraceTimer
211 settimer vampiricEmbraceTimer cdVampiricEmbrace
212endif
213
214if not timerexists corpseSkinTimer
215 createtimer corpseSkinTimer
216 settimer corpseSkinTimer cdCorpseSkin
217endif
218
219if not timerexists mindRotTimer
220 createtimer mindRotTimer
221 settimer mindRotTimer cdMindRot
222endif
223
224if not timerexists meditiationTimer
225 createtimer meditiationTimer
226 settimer meditiationTimer cdMeditation
227endif
228
229if not timerexists killTargetTimer
230 createtimer killTargetTimer
231 settimer killTargetTimer cdKillTarget
232endif
233
234if not timerexists witherTimer
235 createtimer witherTimer
236 settimer witherTimer cdWither
237endif
238
239if not timerexists vengefulSpiritTimer
240 createtimer vengefulSpiritTimer
241 settimer vengefulSpiritTimer cdVengefulSpirit
242endif
243
244if not timerexists bloodOathTimer
245 createtimer bloodOathTimer
246 settimer bloodOathTimer cdBloodOath
247endif
248
249if not timerexists painSpikeTimer
250 createtimer painSpikeTimer
251 settimer painSpikeTimer cdPainSpike
252endif
253
254if not timerexists preventOverheadSpamTimer
255 createtimer preventOverheadSpamTimer
256 settimer preventOverheadSpamTimer cdPreventOverheadSpam
257endif
258
259if not varexist myEarthPet
260 @setvar! myEarthPet 0
261endif
262if not varexist myWaterPet
263 @setvar! myWaterPet 0
264endif
265if not varexist mySummonAnimalPet
266 @setvar! mySummonAnimalPet 0
267endif
268
269// make sure we have enough symbols to summon (6 for wither + vengful spirit)
270if skill "Necromancy" >= 90
271 while followers < 4 and 6 > necroSymbols
272 // we already have vengeful spirit active, skip the check
273 if timer vengefulSpiritTimer < cdVengefulSpirit
274 break
275 endif
276 if diffhits >= 30
277 if targetexists
278 hotkey 'Cancel Current Target'
279 endif
280 while not targetexists 'beneficial'
281 if diffhits >= 60
282 cast 'Heal'
283 else
284 cast 'Greater Heal'
285 endif
286 wait 50
287 if hp = maxhp
288 hotkey '> Interrupt'
289 break
290 endif
291 endwhile
292 if targetexists 'beneficial'
293 hotkey 'Target Self'
294 endif
295 endif
296 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
297 overhead "waiting for symbols" 88
298 settimer preventOverheadSpamTimer 0
299 endif
300 if gumpexists 622436516 and skill "Necromancy" >= 50
301 if ingump "12/" 622436516
302 @setvar! necroSymbols 12
303 elseif ingump "11/" 622436516
304 @setvar! necroSymbols 11
305 elseif ingump "10/" 622436516
306 @setvar! necroSymbols 10
307 elseif ingump "9/" 622436516
308 @setvar! necroSymbols 9
309 elseif ingump "8/" 622436516
310 @setvar! necroSymbols 8
311 elseif ingump "7/" 622436516
312 @setvar! necroSymbols 7
313 elseif ingump "6/" 622436516
314 @setvar! necroSymbols 6
315 elseif ingump "5/" 622436516
316 @setvar! necroSymbols 5
317 elseif ingump "4/" 622436516
318 @setvar! necroSymbols 4
319 elseif ingump "3/" 622436516
320 @setvar! necroSymbols 3
321 elseif ingump "2/" 622436516
322 @setvar! necroSymbols 2
323 elseif ingump "1/" 622436516
324 @setvar! necroSymbols 1
325 elseif ingump "0/" 622436516
326 @setvar! necroSymbols 0
327 endif
328 endif
329 endwhile
330endif
331
332if diffhits < 30
333 if followers = 0
334 @setvar! followCount 0
335 elseif followers = 1
336 @setvar! followCount 1
337 elseif followers = 2
338 @setvar! followCount 2
339 elseif followers = 3
340 @setvar! followCount 3
341 elseif followers = 4
342 @setvar! followCount 4
343 elseif followers = 5
344 @setvar! followCount 5
345 endif
346 if dead myEarthPet or not find myEarthPet ground -1 -1 12
347 if followers < 4
348 while mana < 50
349 if diffhits >= 30
350 replay
351 endif
352 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
353 overhead "waiting for mana" 88
354 settimer preventOverheadSpamTimer 0
355 endif
356 if not findbuff "Actively Meditating"
357 useskill "meditation"
358 endif
359 wait 200
360 endwhile
361 if skill "Necromancy" >= 50 and timer vengefulSpiritTimer >= cdVengefulSpirit
362 yell "[VengefulSpirit"
363 settimer vengefulSpiritTimer 0
364 wait 500
365 endif
366 while followers = followCount
367 cast "earth elemental"
368 wait 500
369 if skill "Necromancy" >= 90 and timer witherTimer >= cdWither
370 yell "[Wither"
371 settimer witherTimer 0
372 endif
373 if diffhits >= 30
374 hotkey '> Interrupt'
375 replay
376 break
377 endif
378 endwhile
379 // 158 - an ancient mummy
380 if findtype 158 ground -1 -1 6 as myPet
381 if noto myPet = "friend" and list petNameList > 0
382 overhead "Renaming..."
383 foreach petName in petNameList
384 rename myPet petName
385 break
386 endfor
387 poplist petNameList "front"
388 endif
389 @setvar! myEarthPet myPet
390 say "all guard me"
391 replay
392 endif
393 endif
394 endif
395endif
396
397if diffhits < 30
398 if followers = 0
399 @setvar! followCount 0
400 elseif followers = 1
401 @setvar! followCount 1
402 elseif followers = 2
403 @setvar! followCount 2
404 elseif followers = 3
405 @setvar! followCount 3
406 elseif followers = 4
407 @setvar! followCount 4
408 elseif followers = 5
409 @setvar! followCount 5
410 endif
411 if dead myWaterPet or not find myWaterPet ground -1 -1 12
412 if followers < 4
413 while mana < 50
414 if diffhits >= 30
415 replay
416 endif
417 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
418 overhead "waiting for mana" 88
419 settimer preventOverheadSpamTimer 0
420 endif
421 if not findbuff "Actively Meditating"
422 useskill "meditation"
423 endif
424 wait 200
425 endwhile
426 if timer vengefulSpiritTimer >= cdVengefulSpirit
427 yell "[VengefulSpirit"
428 settimer vengefulSpiritTimer 0
429 wait 500
430 endif
431 while followers = followCount
432 cast "fire elemental"
433 wait 500
434 if timer witherTimer >= cdWither
435 yell "[Wither"
436 settimer witherTimer 0
437 endif
438 if diffhits >= 30
439 hotkey '> Interrupt'
440 break
441 endif
442 endwhile
443 // 24 - a lich
444 if findtype 24 ground -1 -1 6 as myPet
445 if noto myPet = "friend" and list petNameList > 0
446 overhead "Renaming..."
447 foreach petName in petNameList
448 rename myPet petName
449 break
450 endfor
451 poplist petNameList "front"
452 endif
453 @setvar! myWaterPet myPet
454 say "all guard me"
455 replay
456 endif
457 endif
458 endif
459endif
460
461if followers = 4 and diffhits < 30
462 while mana < 14
463 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
464 overhead "waiting for mana" 88
465 settimer preventOverheadSpamTimer 0
466 endif
467 if diffhits >= 30
468 replay
469 endif
470 if not findbuff "Actively Meditating"
471 useskill "meditation"
472 endif
473 wait 200
474 endwhile
475 if timer vengefulSpiritTimer >= cdVengefulSpirit
476 yell "[VengefulSpirit"
477 settimer vengefulSpiritTimer 0
478 wait 200
479 endif
480 while followers = followCount
481 cast 'Summ. Creature'
482 wait 500
483 if diffhits >= 30
484 hotkey '> Interrupt'
485 replay
486 endif
487 endwhile
488 say "all guard me"
489endif
490
491if diffhits >= 30
492 if targetexists
493 hotkey 'Cancel Current Target'
494 endif
495 while not targetexists 'beneficial'
496 if diffhits >= 60
497 cast 'Heal'
498 else
499 cast 'Greater Heal'
500 endif
501 wait 50
502 if hp = maxhp
503 hotkey '> Interrupt'
504 break
505 endif
506 endwhile
507 if targetexists 'beneficial'
508 target self
509 endif
510 replay
511endif
512
513# Eat food if we got it
514if not findbuff "food" and findtype "tray" backpack as jood
515 dclick jood
516 wait 200
517endif
518
519# Use Taste ID if possible
520if skill "Taste Identification" >= 50 and not findbuff "herb" and timer meditiationTimer >= 11000
521 useskill 'tasteidentification'
522 wft 500
523 target backpack
524 settimer meditiationTimer 0
525endif
526
527if setThisAsOneIfYouWantToTargetYourOwnKillOrItWillTargetClosestMonster = 1
528 say "all kill"
529 wait 200
530 while targetexists
531 // wait
532 wait 50
533 endwhile
534else
535 hotkey 'Target Closest Non-Friendly Monster'
536 wait 200
537 if insysmsg "No one matching that was found"
538 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
539 overhead "found no one" 34
540 settimer preventOverheadSpamTimer 0
541 endif
542 if autoBotEnabled = 1
543 wait 500
544 replay
545 endif
546 stop
547 elseif not find lasttarget ground -1 -1 8
548 overhead "● ▼▼ HERE ▼▼ ●" 88 lasttarget
549 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
550 overhead "Move closer, more then 8 tiles away" 34
551 settimer preventOverheadSpamTimer 0
552 endif
553 if autoBotEnabled = 1
554 wait 500
555 replay
556 endif
557 stop
558 else
559 overhead "● ▼▼ HERE ▼▼ ●" 88 lasttarget
560 endif
561endif
562
563@setvar myKillTarget lasttarget
564
565if not varexist myPreviousKillTarget
566 @setvar myPreviousKillTarget 0
567endif
568
569getlabel myKillTarget desc
570overhead desc
571
572if not varexist myEarthPet or dead myEarthPet
573 overhead "Resummoning" 34
574 if findtype "an ancient mummy" ground -1 -1 10 as maybePet
575 if noto maybePet = "friend"
576 @setvar! myEarthPet maybePet
577 replay
578 endif
579 endif
580else
581 menu myEarthPet 2
582 wft 500
583 target myKillTarget
584endif
585
586if diffhits >= 30 and mana > 12
587 while not targetexists
588 if diffhits >= 60
589 cast 'Heal'
590 else
591 cast 'Greater Heal'
592 endif
593 wait 50
594 if hp = maxhp
595 hotkey '> Interrupt'
596 break
597 endif
598 endwhile
599 if targetexists
600 target self
601 endif
602elseif castBless = 1 and str <= 100
603 while not targetexists
604 cast 'Bless'
605 wait 50
606 if diffhits >= 30
607 hotkey '> Interrupt'
608 break
609 endif
610 endwhile
611 if targetexists
612 target self
613 endif
614endif
615
616if not listexists myCursedTargets
617 createlist myCursedTargets
618endif
619
620if not listexists myManaDrainTargets
621 createlist myManaDrainTargets
622endif
623
624if find myKillTarget -1 -1 12 as killy
625 if myKillTarget = myPreviousKillTarget
626 // do nothing
627 else
628
629 // Herding using crook
630 if skill "Herding" > 0 and findtype 3713 backpack as jrook
631 dclick jrook
632 wft 500
633 target killy
634 endif
635
636 if inlist myManaDrainTargets myKillTarget
637 overhead "Target currently mana drained" 88
638 // do nothing
639 elseif castManadrain = 0
640 // do nothing
641 else
642 while not targetexists and not dead myKillTarget
643 if diffhits < 30
644 cast 'mana drain'
645 wait 50
646 elseif diffhits >= 30
647 hotkey '> Interrupt'
648 break
649 endif
650 endwhile
651 if targetexists
652 target myKillTarget
653 pushlist myManaDrainTargets myKillTarget
654 settimer killTargetTimer 0
655 wait 500
656 endif
657 endif
658
659 if inlist myCursedTargets myKillTarget
660 overhead "Target currently cursed" 88
661 // do nothing
662 elseif castCurse = 0
663 // do nothing
664 else
665 while not targetexists and not dead myKillTarget
666 if diffhits < 30
667 cast 'Curse'
668 wait 50
669 elseif diffhits >= 30
670 hotkey '> Interrupt'
671 break
672 endif
673 endwhile
674 if targetexists
675 target myKillTarget
676 pushlist myCursedTargets myKillTarget
677 settimer killTargetTimer 0
678 wait 500
679 endif
680 endif
681 @setvar myPreviousKillTarget myKillTarget
682 endif
683else
684 overhead "Out of range" 34
685endif
686
687
688clearsysmsg
689
690say "all guard"
691
692@setvar! isLethalPoison 0
693@setvar! isDiscorded 0
694@setvar! isHerded 0
695
696while not dead myKillTarget and find myKillTarget -1 -1 12 as killy
697
698 if skill "Herding" > 0 and isHerded = 0 and timer meditiationTimer >= 11000 and findtype 3713 backpack as jrook
699 dclick jrook
700 wft 500
701 target myKillTarget
702 settimer meditiationTimer 8000
703 @setvar! isHerded 1
704 endif
705
706 if gumpexists 622436516 and skill "Necromancy" >= 50
707 if ingump "12/" 622436516
708 @setvar! necroSymbols 12
709 elseif ingump "11/" 622436516
710 @setvar! necroSymbols 11
711 elseif ingump "10/" 622436516
712 @setvar! necroSymbols 10
713 elseif ingump "9/" 622436516
714 @setvar! necroSymbols 9
715 elseif ingump "8/" 622436516
716 @setvar! necroSymbols 8
717 elseif ingump "7/" 622436516
718 @setvar! necroSymbols 7
719 elseif ingump "6/" 622436516
720 @setvar! necroSymbols 6
721 elseif ingump "5/" 622436516
722 @setvar! necroSymbols 5
723 elseif ingump "4/" 622436516
724 @setvar! necroSymbols 4
725 elseif ingump "3/" 622436516
726 @setvar! necroSymbols 3
727 elseif ingump "2/" 622436516
728 @setvar! necroSymbols 2
729 elseif ingump "1/" 622436516
730 @setvar! necroSymbols 1
731 elseif ingump "0/" 622436516
732 @setvar! necroSymbols 0
733 endif
734 endif
735
736 if skill "Discordance" >= 50
737 if isDiscorded = 0
738 getlabel myKillTarget discordDesc
739 if "discord" in discordDesc
740 @setvar! isDiscorded 1
741 elseif timer meditiationTimer >= 11000
742 useskill 'Discordance'
743 wft 500
744 if insysmsg "What instrument"
745 if findtype "bamboo flute" backpack as inny
746 target inny
747 elseif findtype "tambourine" backpack as inny
748 target inny
749 elseif findtype "drum" backpack as inny
750 target inny
751 elseif findtype "lute" backpack as inny
752 target inny
753 elseif findtype "harp" backpack as inny
754 target inny
755 elseif findtype "lap harp" backpack as inny
756 target inny
757 else
758 overhead "I do not have an inny" 34
759 @setvar! isDiscorded 1
760 endif
761 wft 500
762 endif
763 if targetexists
764 target myKillTarget
765 overhead "Discorded" 88 myKillTarget
766 endif
767 settimer meditiationTimer 5000
768 endif
769 endif
770
771 if not findbuff "song of discordance" and timer meditiationTimer >= 11000
772 useskill 'Discordance'
773 wft 500
774 if insysmsg "What instrument"
775 if findtype "bamboo flute" backpack as inny
776 target inny
777 elseif findtype "tambourine" backpack as inny
778 target inny
779 elseif findtype "drum" backpack as inny
780 target inny
781 elseif findtype "lute" backpack as inny
782 target inny
783 elseif findtype "harp" backpack as inny
784 target inny
785 elseif findtype "lap harp" backpack as inny
786 target inny
787 else
788 overhead "I do not have an inny" 34
789 @setvar! isDiscorded 1
790 endif
791 wft 500
792 endif
793 target backpack
794 settimer meditiationTimer 0
795 endif
796 endif
797
798 if followers < 4
799 replay
800 elseif castBloodOath = 1 and timer bloodOathTimer >= cdBloodOath and 5 < necroSymbols
801 yell "[BloodOath"
802 settimer bloodOathTimer 0
803 if gumpexists 622436516
804 if ingump "12/" 622436516
805 @setvar! necroSymbols 12
806 elseif ingump "11/" 622436516
807 @setvar! necroSymbols 11
808 elseif ingump "10/" 622436516
809 @setvar! necroSymbols 10
810 elseif ingump "9/" 622436516
811 @setvar! necroSymbols 9
812 elseif ingump "8/" 622436516
813 @setvar! necroSymbols 8
814 elseif ingump "7/" 622436516
815 @setvar! necroSymbols 7
816 elseif ingump "6/" 622436516
817 @setvar! necroSymbols 6
818 elseif ingump "5/" 622436516
819 @setvar! necroSymbols 5
820 elseif ingump "4/" 622436516
821 @setvar! necroSymbols 4
822 elseif ingump "3/" 622436516
823 @setvar! necroSymbols 3
824 elseif ingump "2/" 622436516
825 @setvar! necroSymbols 2
826 elseif ingump "1/" 622436516
827 @setvar! necroSymbols 1
828 elseif ingump "0/" 622436516
829 @setvar! necroSymbols 0
830 endif
831 endif
832 endif
833
834 if insysmsg "Target cannot be seen."
835 overhead "Target not in line of sight" 34
836 replay
837 endif
838
839 if castMagicShield = 1 and timer magicShieldTimer >= cdMagicShield and not findbuff "Magic Reflection"
840 cast "Magic Reflection"
841 wait 1000
842 elseif drinkMagicResistPot = 1 and not findbuff "Magic Reflection" and not findbuff "Magic Resist Potion" and findtype "Black Potion" backpack as pot
843 dclick pot
844 wait 200
845 endif
846
847 if findbuff "Magic Reflection"
848 settimer magicShieldTimer 0
849 endif
850
851 if castReactiveArmor = 1 and timer reactiveArmorTimer >= cdReactiveArmor and not findbuff "Reactive Armor"
852 cast "Reactive Armor"
853 wait 200
854 endif
855
856 if findbuff "Reactive Armor"
857 settimer reactiveArmorTimer 0
858 endif
859 if castCorpseSkin = 1 and timer corpseSkinTimer >= cdCorpseSkin and skill "Necromancy" >= 65 and timer meditiationTimer >= cdMeditationMini and 2 < necroSymbols
860 yell "[CorpseSkin"
861 settimer corpseSkinTimer 0
862 cooldown CorpseSkin cdCorpseSkin
863 wait 500
864 if gumpexists 622436516
865 if ingump "12/" 622436516
866 @setvar! necroSymbols 12
867 elseif ingump "11/" 622436516
868 @setvar! necroSymbols 11
869 elseif ingump "10/" 622436516
870 @setvar! necroSymbols 10
871 elseif ingump "9/" 622436516
872 @setvar! necroSymbols 9
873 elseif ingump "8/" 622436516
874 @setvar! necroSymbols 8
875 elseif ingump "7/" 622436516
876 @setvar! necroSymbols 7
877 elseif ingump "6/" 622436516
878 @setvar! necroSymbols 6
879 elseif ingump "5/" 622436516
880 @setvar! necroSymbols 5
881 elseif ingump "4/" 622436516
882 @setvar! necroSymbols 4
883 elseif ingump "3/" 622436516
884 @setvar! necroSymbols 3
885 elseif ingump "2/" 622436516
886 @setvar! necroSymbols 2
887 elseif ingump "1/" 622436516
888 @setvar! necroSymbols 1
889 elseif ingump "0/" 622436516
890 @setvar! necroSymbols 0
891 endif
892 endif
893 endif
894
895 if skill "poisoning" >= 100 or castPoisonAnyway = 1
896 if timer meditiationTimer >= cdMeditationMini
897 if castMindRot = 1 and timer mindRotTimer >= cdMindRot and skill "Necromancy" >= 75 and 3 < necroSymbols
898 yell "[MindRot"
899 settimer mindRotTimer 0
900 wait 500
901 if gumpexists 622436516
902 if ingump "12/" 622436516
903 @setvar! necroSymbols 12
904 elseif ingump "11/" 622436516
905 @setvar! necroSymbols 11
906 elseif ingump "10/" 622436516
907 @setvar! necroSymbols 10
908 elseif ingump "9/" 622436516
909 @setvar! necroSymbols 9
910 elseif ingump "8/" 622436516
911 @setvar! necroSymbols 8
912 elseif ingump "7/" 622436516
913 @setvar! necroSymbols 7
914 elseif ingump "6/" 622436516
915 @setvar! necroSymbols 6
916 elseif ingump "5/" 622436516
917 @setvar! necroSymbols 5
918 elseif ingump "4/" 622436516
919 @setvar! necroSymbols 4
920 elseif ingump "3/" 622436516
921 @setvar! necroSymbols 3
922 elseif ingump "2/" 622436516
923 @setvar! necroSymbols 2
924 elseif ingump "1/" 622436516
925 @setvar! necroSymbols 1
926 elseif ingump "0/" 622436516
927 @setvar! necroSymbols 0
928 endif
929 endif
930 endif
931
932 while isLethalPoison = 0
933
934 if insysmsg "Target cannot be seen."
935 overhead "Target not in line of sight" 34
936 replay
937 endif
938
939 getlabel myKillTarget desc2
940 overhead desc2 66
941 // poison lethal
942 if "Lethal" in desc2
943 @setvar! isLethalPoison 1
944 break
945 elseif castPoisonAnyway = 1 and "Ticks" in desc2
946 @setvar! isLethalPoison 1
947 break
948 elseif castPoisonAnyway = 1 and "Poison" in desc2
949 @setvar! isLethalPoison 1
950 break
951 elseif diffhits >= 30
952 // need a heal
953 break
954 elseif mana >= 9
955 while not targetexists
956 cast 'poison'
957 wait 50
958 if dead myKillTarget
959 hotkey '> Interrupt'
960 replay
961 endif
962 endwhile
963 target myKillTarget
964 wait 200
965 if insysmsg "Target cannot be seen."
966 overhead "CANNOT BE SEEN MOVE TO NEXT TARGET" 34
967 @setvar! isLethalPoison 1
968 endif
969 else
970 wait 200
971 endif
972 endwhile
973 endif
974 endif
975
976 if castEvilOmen = 1 and timer evilOmenTimer >= cdEvilOmen and skill "Necromancy" >= 60 and timer meditiationTimer >= cdMeditationMini and 2 < necroSymbols
977 yell "[EvilOmen"
978 settimer evilOmenTimer 0
979 cooldown EvilOmen cdEvilOmen
980 wait 500
981 if gumpexists 622436516
982 if ingump "12/" 622436516
983 @setvar! necroSymbols 12
984 elseif ingump "11/" 622436516
985 @setvar! necroSymbols 11
986 elseif ingump "10/" 622436516
987 @setvar! necroSymbols 10
988 elseif ingump "9/" 622436516
989 @setvar! necroSymbols 9
990 elseif ingump "8/" 622436516
991 @setvar! necroSymbols 8
992 elseif ingump "7/" 622436516
993 @setvar! necroSymbols 7
994 elseif ingump "6/" 622436516
995 @setvar! necroSymbols 6
996 elseif ingump "5/" 622436516
997 @setvar! necroSymbols 5
998 elseif ingump "4/" 622436516
999 @setvar! necroSymbols 4
1000 elseif ingump "3/" 622436516
1001 @setvar! necroSymbols 3
1002 elseif ingump "2/" 622436516
1003 @setvar! necroSymbols 2
1004 elseif ingump "1/" 622436516
1005 @setvar! necroSymbols 1
1006 elseif ingump "0/" 622436516
1007 @setvar! necroSymbols 0
1008 endif
1009 endif
1010 endif
1011
1012 if castVampiricEmbrace = 1 and timer vampiricEmbraceTimer >= cdVampiricEmbrace and skill "Necromancy" >= 75 and timer meditiationTimer >= cdMeditationMini and 3 < necroSymbols and findtype 8198 ground -1 -1 4 as jorpse
1013 yell "[VampiricEmbrace"
1014 wft 500
1015 target jorpse
1016 settimer vampiricEmbraceTimer 0
1017 cooldown VampiricEmbrace cdVampiricEmbrace
1018 wait 500
1019 if gumpexists 622436516
1020 if ingump "12/" 622436516
1021 @setvar! necroSymbols 12
1022 elseif ingump "11/" 622436516
1023 @setvar! necroSymbols 11
1024 elseif ingump "10/" 622436516
1025 @setvar! necroSymbols 10
1026 elseif ingump "9/" 622436516
1027 @setvar! necroSymbols 9
1028 elseif ingump "8/" 622436516
1029 @setvar! necroSymbols 8
1030 elseif ingump "7/" 622436516
1031 @setvar! necroSymbols 7
1032 elseif ingump "6/" 622436516
1033 @setvar! necroSymbols 6
1034 elseif ingump "5/" 622436516
1035 @setvar! necroSymbols 5
1036 elseif ingump "4/" 622436516
1037 @setvar! necroSymbols 4
1038 elseif ingump "3/" 622436516
1039 @setvar! necroSymbols 3
1040 elseif ingump "2/" 622436516
1041 @setvar! necroSymbols 2
1042 elseif ingump "1/" 622436516
1043 @setvar! necroSymbols 1
1044 elseif ingump "0/" 622436516
1045 @setvar! necroSymbols 0
1046 endif
1047 endif
1048 endif
1049
1050
1051 if castPainSpike = 1 and timer painSpikeTimer >= cdPainSpike and skill "Necromancy" >= 95 and timer meditiationTimer >= cdMeditationMini and 5 < necroSymbols and findtype 8198 ground -1 -1 6 as jorpse
1052 yell "[PainSpike"
1053 wft 500
1054 target myKillTarget
1055 wait 200
1056 if insysmsg "You do not see any corpses"
1057 overhead "No corpse in range" 34
1058 else
1059 settimer painSpikeTimer 0
1060 cooldown PainSpike cdPainSpike
1061 endif
1062 if gumpexists 622436516
1063 if ingump "12/" 622436516
1064 @setvar! necroSymbols 12
1065 elseif ingump "11/" 622436516
1066 @setvar! necroSymbols 11
1067 elseif ingump "10/" 622436516
1068 @setvar! necroSymbols 10
1069 elseif ingump "9/" 622436516
1070 @setvar! necroSymbols 9
1071 elseif ingump "8/" 622436516
1072 @setvar! necroSymbols 8
1073 elseif ingump "7/" 622436516
1074 @setvar! necroSymbols 7
1075 elseif ingump "6/" 622436516
1076 @setvar! necroSymbols 6
1077 elseif ingump "5/" 622436516
1078 @setvar! necroSymbols 5
1079 elseif ingump "4/" 622436516
1080 @setvar! necroSymbols 4
1081 elseif ingump "3/" 622436516
1082 @setvar! necroSymbols 3
1083 elseif ingump "2/" 622436516
1084 @setvar! necroSymbols 2
1085 elseif ingump "1/" 622436516
1086 @setvar! necroSymbols 1
1087 elseif ingump "0/" 622436516
1088 @setvar! necroSymbols 0
1089 endif
1090 endif
1091 endif
1092
1093 if find myKillTarget -1 -1 12 as killy
1094 // do nothing
1095 else
1096 overhead "Out of range" 34
1097 break
1098 endif
1099
1100 if poisoned
1101 if findtype "Orange Potion" backpack as pot
1102 dclick pot
1103 wait 200
1104 else
1105 while not targetexists
1106 if not poisoned
1107 hotkey '> Interrupt'
1108 break
1109 else
1110 cast 'Cure'
1111 wait 50
1112 endif
1113 endwhile
1114 if targetexists
1115 target self
1116 wait 500
1117 endif
1118 endif
1119 endif
1120
1121 if diffmana >= 30 and timer magicMushroomTimer >= cdMushroom and findtype "mushroom" backpack as mushy
1122 overhead "Eating shrooms" 66
1123 dclick mushy
1124 settimer magicMushroomTimer 0
1125 endif
1126
1127 if castLightning = 1 and diffhits < 30 and mana >= 12 and timer lightningTimer >= cdLightning and timer meditiationTimer >= cdMeditationMini
1128 while not targetexists
1129 if dead myKillTarget or diffhits >= 30
1130 hotkey '> Interrupt'
1131 break
1132 else
1133 cast 'Lightning'
1134 wait 50
1135 endif
1136 endwhile
1137 if targetexists
1138 target myKillTarget
1139 settimer lightningTimer 0
1140 cooldown Lightning cdLightning
1141 wait 500
1142 endif
1143 endif
1144
1145 if castMagicArrow = 1 and diffhits < 30 and mana >= 5 and timer magicArrowTimer >= cdMagicArrow and timer meditiationTimer >= cdMeditationMini
1146 while not targetexists
1147 if dead myKillTarget or diffhits >= 30
1148 hotkey '> Interrupt'
1149 break
1150 else
1151 cast 'magic arrow'
1152 wait 50
1153 endif
1154 endwhile
1155 if targetexists
1156 target myKillTarget
1157 settimer magicArrowTimer 0
1158 cooldown MagicArrow cdMagicArrow
1159 wait 500
1160 endif
1161 endif
1162
1163 if castHarm = 1 and diffhits < 30 and mana >= 9 and timer harmTimer >= cdHarm and timer meditiationTimer >= cdMeditationMini
1164 while not targetexists
1165 if dead myKillTarget or diffhits >= 30
1166 hotkey '> Interrupt'
1167 break
1168 else
1169 cast 'harm'
1170 wait 50
1171 endif
1172 endwhile
1173 if targetexists
1174 target myKillTarget
1175 settimer harmTimer 0
1176 cooldown Harm cdHarm
1177 wait 500
1178 endif
1179 endif
1180
1181 if castFireball = 1 and diffhits < 30 and mana >= 12 and timer fireballTimer >= cdFireball and timer meditiationTimer >= cdMeditationMini
1182 while not targetexists
1183 if dead myKillTarget or diffhits >= 30
1184 hotkey '> Interrupt'
1185 break
1186 else
1187 cast 'fireball'
1188 wait 50
1189 endif
1190 endwhile
1191 if targetexists
1192 target myKillTarget
1193 settimer fireballTimer 0
1194 cooldown Fireball cdFireball
1195 wait 500
1196 endif
1197 endif
1198
1199 if diffmana >= 30 and timer magicMushroomTimer >= cdMushroom and findtype "mushroom" backpack as mushy
1200 overhead "Eating mushroom" 66
1201 dclick mushy
1202 settimer magicMushroomTimer 0
1203 endif
1204
1205 if diffhits >= 30
1206
1207 if findtype "Yellow Potion" backpack as pot
1208 getlabel pot desc
1209 if "next usable" in desc
1210 // do nothing
1211 else
1212 dclick pot
1213 wait 200
1214 endif
1215 endif
1216
1217 if diffhits >= 30 and mana >= 12
1218 while not targetexists
1219 if diffhits >= 60
1220 cast 'Heal'
1221 else
1222 cast 'Greater Heal'
1223 endif
1224 wait 50
1225 if hp = maxhp
1226 hotkey '> Interrupt'
1227 break
1228 endif
1229 endwhile
1230 if targetexists
1231 target self
1232 wait 50
1233 endif
1234 endif
1235 elseif mana < 55 and findbuff "actively meditating"
1236 // wait for mana
1237 elseif timer meditiationTimer < cdMeditationMini and findbuff "actively meditating"
1238 // wait for mana
1239 elseif spamMindBlastOverFlamestrike = 1 mana > 42
1240 while not targetexists and mana > 40
1241 if dead myKillTarget or diffhits >= 30
1242 hotkey '> Interrupt'
1243 break
1244 else
1245 cast 'Mind Blast'
1246 wait 50
1247 endif
1248 endwhile
1249 if targetexists
1250 target myKillTarget
1251 wait 500
1252 endif
1253 elseif spamMindBlastOverFlamestrike = 2 mana > 42
1254 while not targetexists and mana > 40
1255 if dead myKillTarget or diffhits >= 30
1256 hotkey '> Interrupt'
1257 break
1258 else
1259 cast 'Mind Blast'
1260 wait 50
1261 endif
1262 endwhile
1263 if targetexists
1264 target myKillTarget
1265 wait 500
1266 endif
1267 while not targetexists and mana > 40
1268 if dead myKillTarget or diffhits >= 30
1269 hotkey '> Interrupt'
1270 break
1271 else
1272 cast 'Flamestrike'
1273 wait 50
1274 endif
1275 endwhile
1276 if targetexists
1277 target myKillTarget
1278 wait 500
1279 endif
1280 elseif mana > 42
1281 while not targetexists and mana > 40
1282
1283 if diffmana >= 30 and timer magicMushroomTimer >= cdMushroom and findtype "mushroom" backpack as mushy
1284 overhead "Eating mushroom" 66
1285 dclick mushy
1286 settimer magicMushroomTimer 0
1287 endif
1288
1289 if dead myKillTarget or diffhits >= 30
1290 hotkey '> Interrupt'
1291 break
1292 else
1293 cast 'Flamestrike'
1294 wait 50
1295 endif
1296 endwhile
1297 if targetexists
1298 target myKillTarget
1299 wait 500
1300 endif
1301 elseif not findbuff "actively meditating" and timer magicMushroomTimer >= cdMushroom and findtype "mushroom" backpack as mushy
1302 overhead "Eating mushroom" 66
1303 dclick mushy
1304 settimer magicMushroomTimer 0
1305 elseif not findbuff "actively meditating" and timer meditiationTimer >= cdMeditation
1306 say "all guard me"
1307 useskill 'meditation'
1308 settimer meditiationTimer 0
1309 wait 500
1310 endif
1311 wait 50
1312endwhile
1313wait 500
1314if targetexists
1315 hotkey 'Cancel Current Target'
1316endif
1317if not findbuff "actively meditating"
1318 say "all guard me"
1319endif
1320while mana < 50
1321 if setThisAsOneIfYouWantToTargetYourOwnKillOrItWillTargetClosestMonster = 0
1322 hotkey 'Target Closest Non-Friendly Monster'
1323 wait 200
1324 if insysmsg "No one matching that was found"
1325 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
1326 overhead "no next target" 34
1327 settimer preventOverheadSpamTimer 0
1328 endif
1329 elseif not find lasttarget ground -1 -1 8
1330 overhead "● ▼▼ NEXT TARGET HERE ▼▼ ●" 88 lasttarget
1331 if timer preventOverheadSpamTimer >= cdPreventOverheadSpam
1332 overhead "Move closer, more then 8 tiles away" 34
1333 settimer preventOverheadSpamTimer 0
1334 endif
1335 else
1336 overhead "● ▼▼ NEXT TARGET HERE ▼▼ ●" 88 lasttarget
1337 attack lasttarget
1338 endif
1339 endif
1340 if diffhits >= 30
1341 if findtype "Yellow Potion" backpack as pot
1342 getlabel pot desc
1343 if "next usable" in desc
1344 // do nothing
1345 else
1346 dclick pot
1347 wait 200
1348 endif
1349 endif
1350 if diffhits >= 30 and mana >= 12
1351 while not targetexists
1352 if diffhits >= 60
1353 cast 'Heal'
1354 else
1355 cast 'Greater Heal'
1356 endif
1357 wait 50
1358 if hp = maxhp
1359 hotkey '> Interrupt'
1360 break
1361 endif
1362 endwhile
1363 if targetexists
1364 target self
1365 wait 50
1366 endif
1367 endif
1368 endif
1369 if not findbuff "actively meditating"
1370 useskill 'meditation'
1371 endif
1372 wait 500
1373endwhile
1374if canYouMakeAMushroom = 1 and counttype "mushroom" backpack < 5
1375 while counttype "mushroom" backpack < 15
1376 cast "Create Food"
1377 wait 200
1378 if diffhits >= 30 or counttype "mushroom" backpack = 0
1379 break
1380 endif
1381 endwhile
1382endif
1383if castVampiricEmbrace = 1 and timer vampiricEmbraceTimer >= cdVampiricEmbrace and skill "Necromancy" >= 70 and findtype 8198 ground -1 -1 4 as jorpse
1384 say "[VampiricEmbrace"
1385 wft 500
1386 target jorpse
1387 settimer vampiricEmbraceTimer 0
1388 cooldown VampiricEmbrace cdVampiricEmbrace
1389endif
1390
1391if timer killTargetTimer >= cdKillTarget
1392 overhead "Curse and mana drain target cleared" 34
1393 removelist myCursedTargets
1394 removelist myManaDrainTargets
1395endif
1396
1397if autoBotEnabled = 1
1398 replay
1399endif
1400
1401// thanks for using a Jaseowns script!
1402// https://www.youtube.com/jaseowns