Train Magery 0 to 100 by alistormccoy
Description: Train Magery 0 to 100 w/ Shelter Dungeon Check and restock with Restock Agent OR storage shelf
1// Train Magery 0 to 100
2
3// Recommended to be in Shelter Dungeon while under 80 magery for increased skill gain!
4// If you do start in Shelter Dungeon, the script will stop when you get to 80 and you will
5// need to leave Shelter Island and restart the script if you want to gain past 80 skill
6// Starting your charcter with 50 Magery, 49 Eval Int, and 1 Necromancy will give you
7// a spellstone with enough charges to get you to 80+ and beyond without needing regs
8// If you are not in Shelter Dungeon, have a Storage Shelf within 2 tiles and a loadout that
9// includes regs OR have Restock Agent 10 set up for regs and a nearby container of regs.
10
11// Regs Consumed:
12// Lightning (50-60): ~100 Mandrake root, Sulfurous Ash
13// Greater Heal (50-60): ~20 Spider Silk, Ginsing, Garlic, Mandrake Root
14// Invisibility (60-80): ~400 Bloodmoss, Nightshade
15// Summon Water Elemental (80 to 100): ~5000 Blood moss, Spiders Silk, Mandrake Root
16
17// If you are getting ^You have not recovered^ messages, try increasing this number by 100
18@setvar! "WaitTimer" 500
19
20// If somehow you have already unlocked Spirit Pact for Water Elemental, set this to 1
21@setvar! "WaterEleSpiritPact" 0
22
23// Set this to 1 if you want to train 50 to 80 outside of shelter dungeon for some reason. NOT RECOMMENDED
24@setvar! "ShelterOverride" 0
25
26
27
28
29// No Edit
30// 4150 hay
31// 3948 trash barrel
32// 3703 moongate
33// xD
34removelist "shelter_checklist"
35createlist "shelter_checklist"
36@setvar! "in_shelter" 0
37if skill "Magery" < 80
38 if "ShelterOverride" = 1
39 elseif findtypelist "shelter_checklist" 4150|3948|3703 "ground" any 1 18 and "ShelterOverride" = 0
40 if atlist "shelter_checklist" 0 and atlist "shelter_checklist" 5 and not atlist "shelter_checklist" 6
41 @setvar! "in_shelter" 1
42 else
43 overhead "Go to the entrance of shelter dungeon first for increased skill gain!" 1159
44 stop
45 endif
46 else
47 overhead "Go to the entrance of shelter dungeon first for increased skill gain!" 1159
48 stop
49 endif
50endif
51
52@setvar! "restock_method" 0
53if "in_shelter" = 1
54elseif findtype "storage shelf" ground 0 1 2 as myStorageShelf
55 @setvar! "restock_method" myStorageShelf
56else
57 overhead "No storage shelf nearby" 1159
58 overhead "Target your restock container" 1159
59 @setvar! "restock_container"
60endif
61
62@setvar "ManaThreshold" 20
63while not dead and skill "Magery" < 100
64 if "in_shelter" = 0
65 if counttype "Blood Moss" < 10 or counttype "Spider's Silk" < 10 or counttype "Mandrake Root%s%" < 10 or counttype "Nightshade" < 10
66 if "restock_method" = 0
67 restock 10
68 wft 200
69 target "restock_container"
70 else
71 menu "restock_method" 1
72 endif
73 endif
74 endif
75
76 if mana < "ManaThreshold"
77 while diffmana > 3
78 if not findbuff "actively meditating"
79 hotkey "Meditation"
80 endif
81 wait 500
82 endwhile
83 elseif skill "Magery" < 50
84 overhead "Train to 50 at an NPC first!" 1159
85 stop
86 elseif skill "Magery" < 60
87 if hp < 40
88 hotkey "Greater Heal"
89 else
90 hotkey "lightning"
91 endif
92 wft 3500
93 hotkey "Target Self"
94 elseif skill "Magery" < 80
95 hotkey "Invisibility"
96 wft 5000
97 hotkey "Target Self"
98 else
99 if "in_shelter" = 1
100 overhead "Time to leave shelter! Cannot gain over 80 in here" 1159
101 stop
102 endif
103 @setvar! "ManaThreshold" 50
104 if findtype "a water elemental" true
105 say "a water elemental release"
106 wait 100
107 endif
108 hotkey "Water Elemental"
109 if "WaterEleSpiritPact" = 1
110 wait 2500
111 else
112 wait 5000
113 endif
114 endif
115 wait "WaitTimer"
116endwhile
117
118overhead "Finished!" 1159