Flu Lumber by flutschi
Related: Lumberjacking
1#its basescript is jasonowns one, just edited for my taste
2
3#create the cooldown 'summons' for keeping up the elementals!
4#create cooldown 'afk' and 'walk' (walk needs to be set to walk in the settings!)
5
6
7@setvar! enableRecall 1
8@setvar! enableSummons 1
9@setvar! enableAFK 1
10
11# use >info on ur woodbag and copy the serial and insert into line 12
12@setvar! woodBag 0x49B39EA9
13
14@setvar! hatchet 3908
15@setvar! pickaxe 3718
16
17@setvar! tool hatchet
18
19clearsysmsg
20
21#this is when u want to summon something
22while casting
23 overhead 'casting..'
24 pause 1000
25endwhile
26
27
28if lhandempty ?? 0
29 if findtype tool backpack
30 dclicktype tool backpack
31 wait 200
32 endif
33endif
34
35if lhandempty ?? 0
36 overhead "No more tools!" 34
37 replay
38endif
39
40# AFK PART
41
42@setvar! afkTime 180000
43@setvar! afkAlert 24000
44@setvar! afkTooLong 5000
45
46if enableAFK = 1
47
48 if cooldown 'afk' < 500
49 cooldown 'afk' afkTime
50 endif
51
52 if cooldown 'walk'
53 cooldown 'afk' afkTime
54 endif
55
56 if cooldown 'afk' < afkAlert
57 overhead 'timer runs out..' 33
58 dclicktype 3834 backpack
59 pause 1500
60 endif
61
62 if cooldown 'afk' < afkTooLong
63 overhead 'afk too long..' 33
64
65 #use runebook
66 dclicktype 8901 backpack
67 waitforgump 1551740969
68 gumpresponse 5
69
70 stop
71
72 script 'recallHome'
73 stop
74 endif
75
76endif
77
78
79# different Chars stuff
80
81if name == 'Flu Miner'
82 @setvar! woodBag 0x49B39EA9
83endif
84if name == 'Flu Logger'
85 @setvar! woodBag 0x44CC0C8C
86endif
87if name == 'Flutschi'
88 @setvar! woodBag 0x40FFC28F
89endif
90if name == 'Flu Log'
91 @setvar! woodBag 0x46281849
92endif
93
94if findtype 7133 backpack as log
95 lift log 999
96 drop woodBag -1 -1 -1
97 pause 200
98endif
99
100if findtype 7133 backpack as log
101 dclick log
102endif
103
104# check for summons
105
106#casttime with summoners tome is 2500, else put 5000
107@setvar! castTime 5200
108
109if enableSummons = 1
110
111 if followers < 1 or cooldown 'summons' < 60000 and mana > 50
112 cast 'Earth Elemental'
113 pause castTime
114 pause 500
115 say 'all guard me'
116 cooldown 'summons' 600000
117 endif
118
119endif
120
121
122# ANTI Thieves
123
124clearignore
125
126if counttype 7127 woodBag 0 > 50
127 overhead 'sorting..'
128 while findtype 3705 backpack 38 as pouch
129 if findtype 7127 woodBag 0 as log
130 lift log 10
131 drop pouch -1 -1 -1
132 pause 700
133 endif
134 ignore pouch
135 endwhile
136endif
137
138clearignore
139
140if counttype 7127 woodBag 2419 > 50
141 overhead 'sorting..'
142 while findtype 3705 backpack 38 as pouch
143 if findtype 7127 woodBag 2419 as log
144 lift log 10
145 drop pouch -1 -1 -1
146 pause 700
147 endif
148 ignore pouch
149 endwhile
150endif
151
152clearignore
153
154if counttype 7127 woodBag 2406 > 50
155 overhead 'sorting..'
156 while findtype 3705 backpack 38 as pouch
157 if findtype 7127 woodBag 2406 as log
158 lift log 10
159 drop pouch -1 -1 -1
160 pause 700
161 endif
162 ignore pouch
163 endwhile
164endif
165
166clearignore
167
168if counttype 7127 woodBag 2413 > 50
169 overhead 'sorting..'
170 while findtype 3705 backpack 38 as pouch
171 if findtype 7127 woodBag 2413 as log
172 lift log 10
173 drop pouch -1 -1 -1
174 pause 700
175 endif
176 ignore pouch
177 endwhile
178endif
179
180clearignore
181
182if counttype 7127 woodBag 2418 > 50
183 overhead 'sorting..'
184 while findtype 3705 backpack 38 as pouch
185 if findtype 7127 woodBag 2418 as log
186 lift log 10
187 drop pouch -1 -1 -1
188 pause 700
189 endif
190 ignore pouch
191 endwhile
192endif
193
194clearignore
195
196if counttype 7127 woodBag 2213 > 50
197 overhead 'sorting..'
198 while findtype 3705 backpack 38 as pouch
199 if findtype 7127 woodBag 2213 as log
200 lift log 10
201 drop pouch -1 -1 -1
202 pause 700
203 endif
204 ignore pouch
205 endwhile
206endif
207
208clearignore
209
210if counttype 7127 woodBag 2425 > 50
211 overhead 'sorting..'
212 while findtype 3705 backpack 38 as pouch
213 if findtype 7127 woodBag 2425 as log
214 lift log 10
215 drop pouch -1 -1 -1
216 pause 700
217 endif
218 ignore pouch
219 endwhile
220endif
221
222clearignore
223
224if counttype 7127 woodBag 2207 > 50
225 overhead 'sorting..'
226 while findtype 3705 backpack 38 as pouch
227 if findtype 7127 woodBag 2207 as log
228 lift log 10
229 drop pouch -1 -1 -1
230 pause 700
231 endif
232 ignore pouch
233 endwhile
234endif
235
236clearignore
237
238if counttype 7127 woodBag 2219 > 50
239 overhead 'sorting..'
240 while findtype 3705 backpack 38 as pouch
241 if findtype 7127 woodBag 2219 as log
242 lift log 10
243 drop pouch -1 -1 -1
244 pause 700
245 endif
246 ignore pouch
247 endwhile
248endif
249
250clearignore
251
252if counttype 7127 woodBag 1763 > 50
253 overhead 'sorting..'
254 while findtype 3705 backpack 38 as pouch
255 if findtype 7127 woodBag 1763 as log
256 lift log 10
257 drop pouch -1 -1 -1
258 pause 700
259 endif
260 ignore pouch
261 endwhile
262endif
263
264clearignore
265
266#tracking!
267
268
269if not findbuff 'tracking'
270 overhead 'i should track..'
271
272 while not gumpexists 4267467659
273 useskill 'tracking'
274 wait 250
275 endwhile
276
277 if gumpexists 4267467659
278 while not insysmsg "You will now hunt all hostile players."
279 gumpresponse 8 4267467659
280 waitforgump 4267467659 5000
281 endwhile
282 gumpresponse 6 4267467659
283 wait 1000
284 clearsysmsg
285 endif
286 gumpclose 4267467659
287endif
288
289#protection!
290
291if not findbuff 'Magic Reflection'
292 cast 'Magic Reflection'
293 pause 3000
294endif
295
296
297#start chopping
298
299wait 500
300overhead 'Lumberjacking' 0
301hotkey 'Use item in hand'
302wft 1000
303hotkey 'Target Self'
304for 75
305 wait 100
306
307 if enableRecall = 1
308 if insysmsg 'Now tracking' or insysmsg 'Distance'
309 #use runebook
310 dclicktype 8901 backpack
311 waitforgump 1551740969
312 gumpresponse 5
313
314 stop
315
316 #this would be if you have my other script.
317 script 'recallHome'
318 stop
319 endif
320 endif
321
322 if cooldown 'walk'
323 cooldown 'afk' afkTime
324 endif
325
326 if cooldown 'afk' < 18000
327 overhead 'timer runs out..' 33
328 dclicktype 3834 backpack
329 pause 1500
330 endif
331
332 if cooldown 'afk' < 3000
333 overhead 'afk too long..' 33
334 guild 'afk too long..'
335 script 'recallHome'
336 stop
337 endif
338
339 if insysmsg 'world is saving'
340 for 30
341 overhead 'Waiting for world save...'
342 wait 1000
343 if insysmsg 'save complete'
344 overhead 'Save complete - continue on!' 88
345 clearsysmsg
346 wait 250
347 replay
348 endif
349 endfor
350 elseif lhandempty ?? 0
351 overhead "Broke axe" 34
352 replay
353 elseif insysmsg 'You do not see any' or insysmsg 'You cannot produce any wood'
354 overhead 'Move to next spot' 88
355 wait 250
356 replay
357 elseif insysmsg "travel"
358 overhead 'Waiting for travel...'
359 wait 1000
360 replay
361 else
362 if insysmsg "any harvestable"
363 overhead 'Move to next spot' 88
364 replay
365 elseif insysmsg "skillgain" or insysmsg "harvesting is not allowed"
366 replay
367 elseif insysmsg "world is saving" or insysmsg 'World save complete'
368 replay
369 elseif insysmsg "You hack"
370 replay
371 elseif insysmsg "You chop"
372 replay
373 elseif insysmsg "You must wait"
374 overhead 'You must wait..' 34
375 wait 500
376 replay
377 endif
378 endif
379endfor
380
381if insysmsg "You must wait"
382 wait 500
383 replay
384endif
385
386
387overhead 'Stopping script' 34