-
Notifications
You must be signed in to change notification settings - Fork 19
/
Copy pathskills-e-itens.pm
242 lines (234 loc) · 7.4 KB
/
skills-e-itens.pm
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
automacro usarPocaoDeAprendiz {
ConfigKeyNot useSelf_item_0 Poção de Aprendiz
InInventory "Poção de Aprendiz" > 0
exclusive 1
call {
log parece que tenho poção de aprendiz, mas ainda não foi configurado pra ser usado
log mudando isso
$potName = pegarNomePeloIdDoItem(569)
do conf useSelf_item_0 $potName
do conf useSelf_item_0_disabled 0
do conf useSelf_item_0_hp < 60%
do conf getAuto_0 $potName
do conf getAuto_0_minAmount 20
do conf getAuto_0_maxAmount 200
do conf getAuto_0_passive 0
log pronto
}
}
automacro parandoDePegarPotDeAprendiz {
InInventoryID 569 < 1
InStorageID 569 < 1
ConfigKey useSelf_item_0 Poção de Aprendiz
exclusive 1
call {
[
log ===================================
log = as poções de aprendiz acabaram,
log = removendo o getAuto
log ===================================
]
#parar de tentar usar tambem
do conf sitAuto_hp_upper 80
do conf getAuto_0 none
if (&config(useSelf_item_0) =~ /Aprendiz/) do conf useSelf_item_0 none
}
}
sub adicionaAttackSkillSlot {
open (my $fh, '>>:encoding(UTF-8)', Settings::getConfigFilename());
print $fh "attackSkillSlot {\n";
print $fh "\tlvl\n";
print $fh "\tdist\n";
print $fh "\tmaxCastTime 0\n";
print $fh "\tminCastTime 0\n";
print $fh "\thp\n";
print $fh "\tsp\n";
print $fh "\thomunculus_hp\n";
print $fh "\thomunculus_sp\n";
print $fh "\thomunculus_dead\n";
print $fh "\tonAction\n";
print $fh "\twhenStatusActive\n";
print $fh "\twhenStatusInactive\n";
print $fh "\twhenFollowing\n";
print $fh "\tspirit\n";
print $fh "\tamuletType\n";
print $fh "\taggressives\n";
print $fh "\tpreviousDamage\n";
print $fh "\tstopWhenHit 0\n";
print $fh "\tinLockOnly 0\n";
print $fh "\tnotInTown 0\n";
print $fh "\ttimeout 0\n";
print $fh "\tdisabled 0\n";
print $fh "\tmonsters\n";
print $fh "\tnotMonsters\n";
print $fh "\tmonstersCount\n";
print $fh "\tmaxAttempts\n";
print $fh "\tmaxUses\n";
print $fh "\ttarget_hp\n";
print $fh "\ttarget_whenStatusActive\n";
print $fh "\ttarget_whenStatusInactive\n";
print $fh "\ttarget_deltaHp\n";
print $fh "\tinInventory\n";
print $fh "\tisSelfSkill\n";
print $fh "\tequip_topHead\n";
print $fh "\tequip_midHead\n";
print $fh "\tequip_lowHead\n";
print $fh "\tequip_leftHand\n";
print $fh "\tequip_rightHand\n";
print $fh "\tequip_leftAccessory\n";
print $fh "\tequip_rightAccessory\n";
print $fh "\tequip_robe\n";
print $fh "\tequip_armor\n";
print $fh "\tequip_shoes\n";
print $fh "\tequip_arrow\n";
print $fh "\tmanualAI 0\n";
print $fh "\tzeny\n";
print $fh "\tnotOnAction\n";
print $fh "}\n";
print $fh "\n"; #deixar uma linha em branco
close ($fh);
}
sub adicionaUseSelfSkill {
open (my $fh, '>>:encoding(UTF-8)', Settings::getConfigFilename());
print $fh "useSelf_skill {\n";
print $fh "\tlvl\n";
print $fh "\tmaxCastTime 0\n";
print $fh "\tminCastTime 0\n";
print $fh "\thp\n";
print $fh "\tsp\n";
print $fh "\thomunculus_hp\n";
print $fh "\thomunculus_sp\n";
print $fh "\thomunculus_dead\n";
print $fh "\tonAction\n";
print $fh "\twhenStatusActive\n";
print $fh "\twhenStatusInactive\n";
print $fh "\twhenFollowing\n";
print $fh "\tspirit\n";
print $fh "\tamuletType\n";
print $fh "\taggressives\n";
print $fh "\tmonsters\n";
print $fh "\tnotMonsters\n";
print $fh "\tmonstersCount\n";
print $fh "\tstopWhenHit\n";
print $fh "\tinLockOnly\n";
print $fh "\tnotWhileSitting\n";
print $fh "\tnotInTown 0\n";
print $fh "\ttimeout 0\n";
print $fh "\tdisabled 0\n";
print $fh "\tinInventory\n";
print $fh "\tmanualAI 0\n";
print $fh "\tnotOnAction\n";
print $fh "}\n";
print $fh "\n"; #deixar uma linha em branco
close ($fh);
}
sub adicionaUseSelfItem {
open (my $fh, '>>:encoding(UTF-8)', Settings::getConfigFilename());
print $fh "useSelf_item {\n";
print $fh "\thp\n";
print $fh "\tsp\n";
print $fh "\thomunculus_hp\n";
print $fh "\thomunculus_sp\n";
print $fh "\thomunculus_dead\n";
print $fh "\tonAction\n";
print $fh "\twhenStatusActive\n";
print $fh "\twhenStatusInactive\n";
print $fh "\twhenFollowing\n";
print $fh "\tspirit\n";
print $fh "\tamuletType\n";
print $fh "\taggressives\n";
print $fh "\tmonsters\n";
print $fh "\tnotMonsters\n";
print $fh "\tmonstersCount\n";
print $fh "\tstopWhenHit 0\n";
print $fh "\tinLockOnly 0\n";
print $fh "\tnotWhileSitting 0\n";
print $fh "\tnotInTown 0\n";
print $fh "\ttimeout\n";
print $fh "\tdisabled 0\n";
print $fh "\tinInventory\n";
print $fh "\tmanualAI 0\n";
print $fh "\tnotOnAction\n";
print $fh "}\n";
print $fh "\n"; #deixar uma linha em branco
close ($fh);
}
sub adicionaBuyAuto {
open (my $fh, '>>:encoding(UTF-8)', Settings::getConfigFilename());
print $fh "buyAuto {\n";
print $fh "\tnpc\n";
print $fh "\tstandpoint\n";
print $fh "\tdistance 5\n";
print $fh "\tprice\n";
print $fh "\tminAmount\n";
print $fh "\tmaxAmount\n";
print $fh "\tbatchSize\n";
print $fh "\tdisabled 0\n";
print $fh "\tzeny\n";
print $fh "}\n";
print $fh "\n"; #deixar uma linha em branco
close ($fh);
}
sub adicionaGetAuto {
open (my $fh, '>>:encoding(UTF-8)', Settings::getConfigFilename());
print $fh "getAuto {\n";
print $fh "\tminAmount\n";
print $fh "\tmaxAmount\n";
print $fh "\tpassive\n";
print $fh "}\n";
print $fh "\n"; #deixar uma linha em branco
close ($fh);
}
sub adicionaBetterShopper {
open (my $fh, '>>:encoding(UTF-8)', Settings::getConfigFilename());
print $fh "BetterShopper {\n";
print $fh "\tmaxPrice\n";
print $fh "\tmaxAmount\n";
print $fh "\tdisabled 0\n";
print $fh "}\n";
print $fh "\n"; #deixar uma linha em branco
close($fh);
}
sub adicionaEnhancedCasting {
open (my $fh, '>>:encoding(UTF-8)', Settings::getConfigFilename());
print $fh "enhancedCasting {\n";
print $fh "\tlvl\n";
print $fh "\tmaxCastTime 0\n";
print $fh "\tminCastTime 0\n";
print $fh "\thp\n";
print $fh "\tsp\n";
print $fh "\tonAction\n";
print $fh "\twhenStatusActive\n";
print $fh "\twhenStatusInactive\n";
print $fh "\twhenFollowing\n";
print $fh "\taggressives\n";
print $fh "\tmonsters\n";
print $fh "\tnotMonsters\n";
print $fh "\tmonstersCount\n";
print $fh "\tstopWhenHit\n";
print $fh "\tinLockOnly\n";
print $fh "\tnotWhileSitting\n";
print $fh "\tnotInTown 0\n";
print $fh "\ttimeout 0\n";
print $fh "\tdisabled 1\n";
print $fh "\tinInventory\n";
print $fh "\tnotOnAction\n";
print $fh "\tblockDelayBeforeUse\n";
print $fh "\tblockDelayAfterUse\n";
print $fh "\ttarget\n";
print $fh "\tnotTarget\n";
print $fh "\tElement\n";
print $fh "\tnotElement\n";
print $fh "\tRace\n";
print $fh "\tnotRace\n";
print $fh "\tSize\n";
print $fh "\tnotSize\n";
print $fh "\tnotImmovable\n";
print $fh "\tdist\n";
print $fh "\tdamageFormula\n";
print $fh "\tdamageType\n";
print $fh "\tfallThrough\n";
print $fh "}\n";
print $fh "\n"; #deixar uma linha em branco
close ($fh);
}