Code
##################
### Переменные ###
######################################################################################
###
var Chest='0x401A826D' ## - ID сундука из которого будем брать логи и класть шафты.
###
var Logs='0x1BDD' ## - Type логов.
###
var Shaft='0x1BD4' ## - Type шафтов.
###
var dagger='0x0F51' ## - Type даггера.
###
#######################################################################################
sub BowCraft()
Open(Chest)
while 1==1
uo.FindType(Logs,-1,'backpack')
while uo.GetQuantity('finditem')==0
uo.FindType(Logs,'0x0000',Chest)
wait(1000)
uo.Grab('1','finditem')
wend
wait(700)
ChekLag()
uo.FindTyp e(Logs,'0x0000','backpack')
uo.WaittargetType(Logs)
uo.Usetype(dagger)
uo.WaitMenu('What do you want to carve the wood into?','shaft (1 log)')
wait(1000)
uo.DeleteJournal()
while not (uo.InJournal('You put') or uo.InJournal('You fail'))
wait(300)
wend
if uo.Weight>100 then
uo.SetReceivingContainer(Chest)
wait(500)
uo.FindType(Shaft)
if uo.GetQuantity('finditem')>0 then
uo.Grab('0','finditem')
wait(3000)
end if
uo.UnSetReceivingContainer()
end if
wend
end sub
sub Open(Container)
uo.DeleteJournal()
uo.UseObject(Container)
repeat
wait(500)
until uo.InJournal('Contains')
end sub
sub ChekLag()
uo.DeleteJournal()
uo.Click('backpack')
repeat
wait(100)
until uo.InJournal("backpack")
end sub