-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuffs.mod
254 lines (231 loc) · 9.48 KB
/
buffs.mod
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
#NOP ==== Buffs, Spells and skills! ====
#TICKER {mana} {#MATH manapercent $curM*100/$maxM} {10}
#TICKER {rebuff} {#IF {$manapercent > 15 && $combat == 0 && $standing == 1} {recast}} {20}
#ACTION {^You lie down and rest your tired bones.$} {#VAR standing 0}
#ACTION {^You go to sleep.$} {#VAR standing 0}
#ACTION {^You stop resting, and stand up.$} {#VAR standing 1}
#ACTION {^You awaken and clamber to your feet.$} {#VAR standing 1}
#SUB {[-- ]} {[LEVEL ME!!]}
#SUB {[--- ]} {[LEVEL ME!!]}
#HIG { [ %1] %2 [LEVEL ME!!]} {cyan}
#HIG {[ %1] %2 [LEVEL ME!!] } {cyan}
#NOP ==== Active Spells ====
#ACTION {^Affecting Spells:$} {#VAR affects 1; #DELAY 1 {#VAR affects 0}}
#ACTION {^Your skin turns to a stone-like substance} {#VAR spell[stone skin] 1}
#ACTION {^You feel slightly healthier.} {#VAR spell[resist poison] 1}
#ACTION {^You feel someone protecting you.} {#VAR spell[armor] 1}
#ACTION {^Your skin takes on a rough, bark-like texture.} {#VAR spell[barkskin] 1}
#ACTION {^You feel a mystical force protecting you.} {#VAR spell[armor] 1}
#ACTION {^You are briefly surrounded by a holy aura.} {#VAR spell[alignment ward] 1}
#ACTION {^You are surrounded by a strong force shield.} {#VAR spell[shield] 1}
#ACTION {^Your eyes tingle.} {affe}
#ACTION {^Your eyes glow red.} {#VAR spell[darksight] 1}
#ACTION {^You feel righteous.} {#VAR spell[bless] 1}
#ACTION {^You feel courageous.$} {#Var spell[courage] 1}
#ACTION {^You feel your awareness improve.$} {#VAR spell[sense life] 1}
#ACTION {^You feel buoyant.} {#VAR spell[waterwalking] 1}
#ACTION {^Your skin turns a little reddish.} {#VAR spell[resist fire] 1}
#ACTION {^Your skin turns a little bluish.} {#VAR spell[resist cold] 1}
#ACTION {^You feel much stronger.} {#VAR spell[strength] 1}
#ACTION {^Your skin turns slightly slippery.} {#VAR spell[freedom] 1}
#ACTION {^You are surrounded in an aura of soft gold.} {#VAR spell[alkar] 1}
#ACTION {^You start to float!} {#VAR spell[float] 1}
#ACTION {^You are encased in a grey, storm-like sphere.} {#VAR spell[stormguard] 1}
#ACTION {^You start glowing.} {#VAR spell[sanctuary] 1}
#ACTION {^You feel inspired.} {#VAR spell[inspiration] 1}
#ACTION {^You no longer feel hunger or thirst.}{#VAR spell[sustenance] 1}
#ACTION {^Ok, you'll try to move silently for a while} {#VAR spell[sneakoutside] 1}
#ACTION {^Ok, but you'll only be sneaky when outside} {#VAR spell[sneakoutside] 1}
#NOP ==== Fading Spells ====
#ACTION {^You feel less protected} {#VAR spell[armor] 0}
#ACTION {^Your barklike skin returns to normal.} {#VAR spell[barkskin] 0}
#ACTION {^The white in your vision fades away} {#VAR spell[detect good] 0}
#ACTION {^Your divine assistance fades} {#VAR spell[bless] 0}
#ACTION {^The yellow in your vision fades away} {#VAR spell[detect invisibility] 0}
#ACTION {^The red in your vision fades away} {#VAR spell[detect evil] 0}
#ACTION {^The blue in your vision fades away} {#VAR spell[detect magic] 0}
#ACTION {^You feel less morally protected} {#VAR spell[alignment ward] 0}
#ACTION {^Your shield of force dissipates} {#VAR spell[shield] 0}
#ACTION {^You feel more timid} {#VAR spell[courage] 0}
#ACTION {^You feel less resistant to poison} {#VAR spell[resist poison] 0}
#ACTION {^You feel less aware of your surroundings} {#VAR spell[sense life] 0}
#ACTION {^You feel less buoyant} {#VAR spell[waterwalking] 0}
#ACTION {^It seems a bit warmer} {#VAR spell[resist fire] 0}
#ACTION {^It seems a bit colder} {#VAR spell[resist cold] 0}
#ACTION {^You feel much weaker} {#VAR spell[strength] 0}
#ACTION {^Your slippery coat melts off of you} {#VAR spell[freedom] 0}
#ACTION {^Your golden aura is snuffed out} {#VAR spell[alkar] 0}
#ACTION {^Your golden aura fades away} {#VAR spell[alkar] 0}
#ACTION {^You feel disoriented as you lose your darksight.} {#VAR spell[darksight] 0}
#ACTION {^You fall abruptly to the ground} {#VAR spell[float] 0}
#ACTION {^You feel dangerously more exposed to the elements} {#VAR spell[stormguard] 0}
#ACTION {^The white aura around your body vanishes!} {#VAR spell[sanctuary] 0}
#ACTION {^The white aura around your body fades.} {#VAR spell[sanctuary] 0}
#ACTION {^You feel much more foolish} {#VAR spell[inspiration] 0}
#ACTION {^Your stomach rumbles.} {#VAR spell[sustenance] 0}
#ACTION {^Your stone skin returns to normal} {#VAR spell[stone skin] 0}
#NOP ==== Affected spells ====
#ACTION {%*{Detect Evil|Detect Good|Bless|Armor|Detect Invisibility|Alignment Ward|Courage|Resist Poison|Detect Magic|Waterwalking|Strength|Freedom|Alkar|Darksight|Float|Stormguard|Sanctuary|Inspiration|Sustenance|Barkskin|Sneak, Outside|Stone Skin}%*}
{
#IF {"%0"=="%*Detect Evil%*" && $affects > 0} {#VAR spell[detect evil] 1};
#IF {"%0"=="%*Detect Good%*" && $affects > 0} {#VAR spell[detect good] 1};
#IF {"%0"=="%*Bless%*" && $affects > 0} {#VAR spell[bless] 1};
#IF {"%0"=="%*Barkskin%*" && $affects > 0} {#VAR spell[barkskin] 1};
#IF {"%0"=="%*Armor%*" && $affects > 0} {#VAR spell[armor] 1};
#IF {"%0"=="%*Detect Invisibility%*" && $affects > 0} {#VAR spell[detect invisibility] 1};
#IF {"%0"=="%*Alignment Ward%*" && $affects > 0} {#VAR spell[alignment ward] 1};
#IF {"%0"=="%*Shield%*" && $affects > 0} {#VAR spell[shield] 1};
#IF {"%0"=="%*Courage%*" && $affects > 0} {#VAR spell[courage] 1};
#IF {"%0"=="%*Resist Poison%*" && $affects > 0} {#VAR spell[resist poison] 1};
#IF {"%0"=="%*Detect Magic%*" && $affects > 0} {#VAR spell[detect magic] 1};
#IF {"%0"=="%*Resist Fire%*" && $affects > 0} {#VAR spell[resist fire] 1};
#IF {"%0"=="%*Resist Cold%*" && $affects > 0} {#VAR spell[resist cold] 1};
#IF {"%0"=="%*Strength%*" && $affects > 0} {#VAR spell[strength] 1};
#IF {"%0"=="%*Freedom%*" && $affects > 0} {#VAR spell[freedom] 1};
#IF {"%0"=="%*Alkar%*" && $affects > 0} {#VAR spell[alkar] 1};
#IF {"%0"=="%*Waterwalking%*" && $affects > 0} {#VAR spell[waterwalking] 1};
#IF {"%0"=="%*Darksight%*" && $affects > 0} {#VAR spell[darksight] 1};
#IF {"%0"=="%*Float%*" && $affects > 0} {#VAR spell[float] 1};
#IF {"%0"=="%*Stormguard%*" && $affects > 0} {#VAR spell[stormguard] 1};
#IF {"%0"=="%*Sanctuary%*" && $affects > 0} {#VAR spell[sanctuary] 1};
#IF {"%0"=="%*Inspiration%*" && $affects > 0} {#VAR spell[inspiration] 1};
#IF {"%0"=="%*Sustenance%*" && $affects > 0} {#VAR spell[sustenance] 1};
#IF {"%0"=="%*Sneak, Outside%*" && $affects > 0} {#VAR spell[sneakoutside] 1};
#IF {"%0"=="%*Stone Skin%*" && $affects > 0} {#VAR spell[stone skin] 1};
#IF {"%0"=="%*Sense Life%*" && $affects > 0} {#VAR spell[sense life] 1}
}
#NOP ==== Rebuffing ====
#ALIAS {resetbuffs}
{
#VAR spell[alignment ward] 0;
#VAR spell[alkar] 0;
#VAR spell[armor] 0;
#VAR spell[barkskin] 0;
#VAR spell[bless] 0;
#VAR spell[courage] 0;
#VAR spell[darksight] 0;
#VAR spell[detect evil] 0;
#VAR spell[detect good] 0;
#VAR spell[detect invisibility] 0;
#VAR spell[detect magic] 0;
#VAR spell[float] 0;
#VAR spell[freedom] 0;
#VAR spell[inspiration] 0;
#VAR spell[resist cold] 0;
#VAR spell[resist fire] 0;
#VAR spell[resist poison] 0;
#VAR spell[sanctuary] 0;
#VAR spell[sense life] 0;
#VAR spell[shield] 0;
#VAR spell[stone skin] 0;
#VAR spell[stormguard] 0;
#VAR spell[strength] 0;
#VAR spell[waterwalking] 0;
#VAR spell[sustenance] 0;
#VAR spell[sneakoutside] 0;
#VAR hunger 0;
#VAR thirst 0;
#DELAY {0.3} {affe}
}
#ALIAS {recast}
{
#FOREACH {*spell[]} {rSpell}
{
#IF {$spell[$rSpell] == 0 && $buff[$rSpell] == 1} {cast '$rSpell';#break}
}
}
#NOP ==== Set, display and save buffs ====
#EVENT {VARIABLE UPDATED spell} {#DELAY {1.5} {printbuffs}}
#NOP Will toggle all buffs on/off for auto recast.
#ALIAS {togglebuff}
{
#FOREACH *buff[] buffitem
{
#IF {$buff[$buffitem] == 1}
{
#VAR togB 0;
#break
};
#ELSE
{
#VAR togB 1
}
};
#FOREACH *buff[] buffitem {#VAR buff[$buffitem] $togB};
printbuffs
}
#ALIAS {setbuff}
{
#IF {"%0" == ""} {#SHOW $buff};
#ELSE
{
#IF {$buff[%0] == 1} {#VAR buff[%0] 0};
#ELSE {#VAR buff[%0] 1}
};
printbuffs
}
#VAR {txtClr}
{
{0}{fbb}
{1}{bfb}
{2}{ }
{3}{ᐅ}
}
#NOP Maybe limit myself to 10 spells for display in right window?
#ALIAS {printbuffs}
{
#IF {&{buff} > 0}
{
#DRAW tile $screenHeight-12-&buff[] 85 $screenHeight-11 110;
#DRAW jeweled box $screenHeight-12-&buff[] 85 $screenHeight-11 109;
#LOOP {0} {&buff[]-1} {i}
{
#VAR {colIx} {$spell[*buff[+$i]]};
#VAR {colJx} {$buff[+$i]};
#MATH colKx $colJx+2;
#SHOW {$txtClr[$colKx] <$txtClr[$colIx]>*buff[+$i]<099>} {$screenHeight-11+$i-&buff[]} {87}
}
}
}
#ALIAS {savebuff}
{
#LOG OVERWRITE {$playerfile};#LOG OFF;
#FOREACH {*buff[]} {test}
{
#LINE LOG {$playerfile} {#VAR {buff[$test]} {$buff[$test]}}
}
}
#NOP ==== Tracker of skillups /w learned ====
#ACTION {^You have become more adept at %1!} {#var learninfo 1;learn %1;#DELAY {1}{#var learninfo 0}}
#ACTION {^You are now a master of %1!} {#var learninfo 1;learn %1;#DELAY {1}{#var learninfo 0}}
#VAR lrnLen 0
#ACTION {[%1] %2 [%3]}
{
#IF {$learninfo == 1}
{
#VAR learnN %2;
#FORMAT learnN %p $learnN;
#LIST outlearn ins -1 { [%3] $learnN};
#IF {&outlearn[] > 5}
{
#LIST outlearn del 1;
#DRAW tile $screenHeight-20 111 $screenHeight-11 116+$lrnLen-1;
#VAR lrnLen 0
};
check_learn_len;
#DRAW tile $screenHeight-20 111 $screenHeight-11 116+$lrnLen-1;
#DRAW jeweled box $screenHeight-17 111 $screenHeight-11 116+$lrnLen-3 $outlearn[%*];
printinfo
}
}
#alias {check_learn_len}
{
#FOREACH $outlearn[%*] len
{
#FORMAT test %L $len;
#IF {$test > $lrnLen}
{
#VAR lrnLen $test
}
}
}