Simple Logging Script by demlar
Related: Lumberjacking
Description: Simple logging script that equips your hatchet with world saves and only waits until chopping is done.
1// Original: Jaseowns
2// Modified: Demlar
3// UO Outlands - https://youtu.be/jTU_pORdan4
4#Version 1.2
5#Cleaned up setvars
6# Added Alerts and recall
7
8@setvar! minimumWaitForPing 200
9
10while not dead
11 if lhandempty
12 if findtype 'hatchet' backpack
13 dclicktype 'hatchet' backpack
14 wait 200
15 else
16 overhead 'Time to buy more hatchets' 88
17 stop
18 endif
19 endif
20
21 // capture world saving outside the loop
22 if insysmsg 'world is saving'
23 for 30
24 overhead 'Waiting for world save...'
25 wait 1000
26 if insysmsg 'save complete'
27 overhead 'Save complete - continue on!' 88
28 replay
29 endif
30 endfor
31 endif
32
33
34 if not varexist jackr_runebook or not find jackr_runebook backpack
35 if counttype "runebook" backpack = 1 and counttype "runetome" backpack = 0 and findtype "runebook" backpack as myBook
36 overhead "Automatically selected your one runebook" 88
37 @setvar jackr_runebook myBook
38 elseif counttype "runebook" backpack = 0 and counttype "runetome" backpack = 1 and findtype "runetome" backpack as myBook
39 overhead "Automatically selected your one runetome" 88
40 @setvar jackr_runebook myBook
41 elseif counttype 7956 backpack = 1 and findtype 7956 backpack as myBook
42 overhead "Automatically selected your one rune" 88
43 @setvar jackr_runebook myBook
44 elseif counttype "runebook" backpack > 0 or counttype 7956 backpack > 0 or counttype "runetome" backpack > 0
45 overhead "Select your escape plan (runebook or runetome)" 88
46 @setvar jackr_runebook
47 endif
48 endif
49
50 if not listexists "alerts"
51 createlist "alerts"
52 endif
53
54
55 if inlist "alerts" "red_alert"
56 overhead "Red Alert!" 34
57 poplist "alerts" "red_alert"
58 # You could also replace this magery bit with your ultimate recaller
59 # Ultimate Recall using Tome or Book as Escape (ALT-M)
60 # https://outlands.uorazorscripts.com/script/5b3fde97-fa90-4707-9f8e-7f56dca6792b
61 # hotkey "Play Script: UltimaRecaller"
62 if skill "Magery" >= 40
63 overhead 'Recalling...'
64 while not targetexists
65 if findtype 8012 backpack as item
66 dclick item
67 else
68 cast "Recall"
69 endif
70 wait minimumWaitForPing
71 if insysmsg "You do not have that spell!"
72 overhead "We cannot recall!" 34
73 break
74 endif
75 endwhile
76 target jackr_runebook
77 elseif skill "Hiding" >= 40
78 useskill "Hiding"
79 endif
80 overhead "Stopping script..." 34
81 stop
82 # replay
83 endif
84
85
86
87 if skill "Tracking" > 0
88 if not findbuff "tracking"
89 while not gumpexists 4267467659
90 useskill 'tracking'
91 wait 200
92 endwhile
93 if gumpexists 4267467659
94 while not insysmsg "You will now hunt all hostile players."
95 gumpresponse 8 4267467659
96 waitforgump 4267467659 5000
97 endwhile
98 gumpresponse 6 4267467659
99 wait 200
100 endif
101 gumpclose 4267467659
102 endif
103 endif
104
105 if not targetexists
106 hotkey "Use item in hand"
107 wft 500
108 endif
109
110 if targetexists
111 hotkey "Target Self"
112 endif
113
114 for 20
115 wait 750
116 if insysmsg "now tracking"
117 pushlist "alerts" "red_alert"
118 replay
119 endif
120 if insysmsg 'You do not see any'
121 break
122 endif
123 if insysmsg 'That must be equipped for'
124 break
125 endif
126 if insysmsg 'You hack at' or insysmsg 'You chop some'
127 break
128 endif
129 // capture world saving inside the loop
130 if insysmsg 'world is saving'
131 for 30
132 overhead 'Waiting for world save...'
133 wait 1000
134 if insysmsg 'save complete'
135 overhead 'Save complete - continue on!' 88
136 replay
137 endif
138 endfor
139 endif
140 endfor
141endwhile