vendor catalog by nesci
Description: This script scans the items of the nearby vendors. It restart the scan after every world saves. It performs better than the other Catalog script by using the findtype command.
1@setvar! globalTimeout 650
2
3# Making sure to hide
4if skill "Hiding" >= 100
5 useskill "hiding"
6endif
7
8clearignore
9sysmsg "START CATALOGUE"
10
11while not dead
12 @hotkey 'Next Monster Target'
13 @setvar! 'lastserial' lasttarget
14 if noto 'lastserial' = invulnerable
15 if findtype 3701 'lastserial' as foundBackpack
16 sysmsg 'New Vendor'
17 say "[coord"
18 sysmsg lastserial
19 dclick 'foundBackpack'
20 @ignore foundBackpack
21 wait globalTimeout
22
23 #Searching for items in main Backpack
24 while findtype 19239|3862|3877|3885|3873|3859|3865|3856|3878|3861|19236|19234|5901|17087|8032|8033|8031|8035|8029|8034|8037|8041|8042|8039|8038|42694|3657|29774|28883|28885|29773|28879|12215|2597|5362|12686|5356|8455|29348|19239|19227|29103|29863|42692|5363|7127|29447|5127|7109|3908|3897|11552|3718|15178|39860|5359|49711|28888|3897|3985|5356|5981|27611|6464|3530|3836|22336|3843|29025|45285|3842|8826|8901|3834|8787|8786|29036|8012|5903|48407|17686|43167|29030|19235|16898|8788|7107|20495|3827|5356|3920|3713|5117|5042|3721|3762|22187|5078|5187|5049|3568|3911|51100|29048|45085|27612|45085|6264|19232 "foundBackpack" as foundItem
25 @getlabel 'foundItem' foundItemLabel
26 sysmsg foundItemLabel 33
27 @ignore foundItem
28 endwhile
29
30 #Open all bags in backpack
31 while findtype 3701|29833|3705|3712|3648|3702 foundBackpack as container
32 getlabel container desc
33 if "Price: Not for sale" in desc
34 dclick container
35 wait globalTimeout
36
37 #Searching for items
38 while findtype 19239|3862|3877|3885|3873|3859|3865|3856|3878|3861|19236|19234|5901|17087|8032|8033|8031|8035|8029|8034|8037|8041|8042|8039|8038|42694|3657|29774|28883|28885|29773|28879|12215|2597|5362|12686|5356|8455|29348|19239|19227|29103|29863|42692|5363|7127|29447|5127|7109|3908|3897|11552|3718|15178|39860|5359|49711|28888|3897|3985|5356|5981|27611|6464|3530|3836|22336|3843|29025|45285|3842|8826|8901|3834|8787|8786|29036|8012|5903|48407|17686|43167|29030|19235|16898|8788|7107|20495|3827|5356|3920|3713|5117|5042|3721|3762|22187|5078|5187|5049|3568|3911|51100|29048|45085|27612|45085|6264|19232 "container" as foundItem
39 @getlabel 'foundItem' foundItemLabel
40 sysmsg foundItemLabel 33
41 @ignore foundItem
42 endwhile
43 endif
44 @ignore container
45 endwhile
46 else
47 overhead 'DONE CATALOGUE'
48
49 # Close all vendor bags
50 walk "North"
51 walk "South"
52
53 # Making sure to hide
54 if skill "Hiding" >= 100
55 useskill "hiding"
56 endif
57
58 clearsysmsg
59 break
60 endif
61 endif
62endwhile
63
64while not insysmsg 'save complete'
65 wait 1000
66endwhile
67
68loop