[Easy UO] Auto Gold Mover
Posted: Mon May 27, 2013 1:00 am
This script will move your gold to a bag of holding or to your bank with a bag of sending (providing your bag has charges on it) when you are over the weight you specify.
Code: Select all
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Auto Gold Move ;
; By: Dramoor ;
; For: Lazy people on the Excelsior Shard. ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
set %bagType 1 ; 1 for bag of sending, 2 for bag of holding.
set %resourceContainer RDKVLPD ; Put the id of either the bag of sending or holding.
set %weightLimit 400 ; Once your weight is over this amount it will put in bag of holding/sending.
gosub checkWeight
return
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Checks the current weight of your character ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
sub checkWeight
if #WEIGHT > %weightLimit
{
event exmsg #charid 3 0 Almost Overweight!
finditem POF C_ , #BACKPACKID
if #FINDCNT > 0
{
if %bagType = 1
gosub SendItems POF
if %bagType = 2
{
event exmsg #charid 3 0 Moving Gold!
for %weightIter 1 #findcnt
{
set #findindex %weightIter
exevent drag #findid #findstack
wait 11
exevent dropc %resourceContainer
wait 11
}
}
}
}
return
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Sends gold to bank with Bag of Sending ;
; ;
; . ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
sub SendItems
namespace push
namespace local SI
set !bos_items %1
SendItems_loop1:
finditem CKF C_ , #BACKPACKID
if #FINDKIND <> -1
{
event property #FINDID
if sending notin #PROPERTY
{
ignoreitem #FINDID
goto SendItems_loop1
}
set !bagofsending #FINDID
SendItems_loop2:
finditem !bos_items C_ , #BACKPACKID
if #FINDKIND <> -1
{
event property !bagofsending
str pos #PROPERTY Charges:
set #STRRES #STRRES + 9
str mid #PROPERTY #STRRES 1
if #STRRES = 0 ; as in zero charges
{
ignoreitem !bagofsending
goto SendItems_loop1
}
set #LOBJECTID !bagofsending
set #LTARGETID #FINDID
set #LTARGETKIND 1
event macro 17
wait 10
target 5s
event macro 22
wait 10
ignoreitem #FINDID
set %weightwarn #FALSE
goto SendItems_loop2
}
}
set %weightwarn #FALSE
namespace pop
return