Code: Select all
sub smelt()
var ore1 = 0x19B7 #Type 1 рудинки
var ore2 = 0x19BA #Type 2 рудинок
var ore3 = 0x19B8 #Type 3 рудинок
var ore4 = 0x19B9 #Type 4 рудинок или более
var delay = 1000 #Задержка на кидание шмота из бекпака
var lasttimer
ore2:
uo.findtype(ore2)
if uo.findcount() > 0 then
UO.Drop('0',0,0,0,'finditem')
wait(delay)
goto ore2
endif
ore3:
uo.findtype(ore3)
if uo.findcount() > 0 then
UO.Drop('0',0,0,0,'finditem')
wait(delay)
goto ore3
endif
ore4:
uo.findtype(ore4)
if uo.findcount() > 0 then
UO.Drop('0',0,0,0,'finditem')
wait(delay)
goto ore4
endif
repeat
uo.findtype(ore4, "-1", "ground")
if uo.findcount() == 0 then
goto ore4_end
endif
uo.grab("1","finditem")
lasttimer = uo.timer()
repeat
wait(100)
uo.findtype(ore1)
until uo.findcount() > 0 or uo.timer()>lasttimer+500
uo.usetype(ore1)
uo.findtype(ore4, "-1", "ground")
until uo.findcount() == 0
ore4_end:
repeat
uo.findtype(ore3, "-1", "ground")
if uo.findcount() == 0 then
goto ore3_end
endif
uo.grab("1","finditem")
lasttimer = uo.timer()
repeat
wait(100)
uo.findtype(ore1)
until uo.findcount() > 0 or uo.timer()>lasttimer+500
uo.usetype(ore1)
uo.findtype(ore3, "-1", "ground")
until uo.findcount() == 0
ore3_end:
repeat
uo.findtype(ore2, "-1", "ground")
if uo.findcount() == 0 then
goto ore2_end
endif
uo.grab("1","finditem")
lasttimer = uo.timer()
repeat
wait(100)
uo.findtype(ore1)
until uo.findcount() > 0 or uo.timer()>lasttimer+500
uo.usetype(ore1)
uo.findtype(ore2, "-1", "ground")
until uo.findcount() == 0
ore2_end:
repeat
uo.findtype(ore1, "-1", "ground")
if uo.findcount() == 0 then
goto ore1_end
endif
uo.grab("1","finditem")
lasttimer = uo.timer()
repeat
wait(100)
uo.findtype(ore1)
until uo.findcount() > 0 or uo.timer()>lasttimer+500
uo.usetype(ore1)
uo.findtype(ore1, "-1", "ground")
until uo.findcount() == 0
ore1_end:
endsub
Вобщем скрипт кидает руду под ноги потом по одной штуке подбирает и плавит.. Но комп, то у меня маленький.... слабенький.. Да еще и ОС вин98. Скидает инги под ноги нормально, а когда начинает плавить, возникает лаг такой, что в итоге при переплавке более полутра тысячи руды инжект зависает...
Что я не так написал?...
ПС: инет лагает ой как блин...