-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathcombine.mac
More file actions
50 lines (47 loc) · 1.35 KB
/
combine.mac
File metadata and controls
50 lines (47 loc) · 1.35 KB
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
#event CombineError "#*#There was no place to put that#*#"
#event CombineError "#*#You cannot combine these items in this container type!#*#"
#event CombineError "#*#You are missing#*#"
#event ContUsed "#*#Someone else is using that. Try again later.#*#"
Sub Main
/declare EndingVar int outer 1
/declare x int local
/if (${Cursor.ID}) {
:auto_inv
/if (${Cursor.Container}) {
/for x 1 to 8
/if (!${InvSlot[pack${x}].Item.Container}) /nomodkey /itemnotify pack${x} leftmouseup
/next x
} else {
/timed 5 /autoinventory
}
/goto :auto_inv
}
:ComboLoop
/autoinventory
/nomodkey /notify TradeskillWnd CombineButton leftmouseup
/doevents
/delay 2
/nomodkey /notify TradeskillWnd AutoInvButton leftmouseup
/if (${EndingVar}==1) /goto :ComboLoop
/if (${Cursor.ID}) {
:auto_inv
/if (${Cursor.Container}) {
/for x 1 to 8
/if (!${InvSlot[pack${x}].Item.Container}) /nomodkey /itemnotify pack${x} leftmouseup
/next x
} else {
/timed 5 /autoinventory
}
/goto :auto_inv
}
/autoinventory
| /nomodkey /notify TradeskillWnd COMBW_CloseButton Leftmouseup
/return
Sub Event_ContUsed
/echo Container in use. Waiting 1 Minute, or until no PCs are nearby and trying again.
/delay 1m ${SpawnCount[pc radius 50]}<=1
/doevents
/return
Sub Event_CombineError
/varset EndingVar 2
/return