и ещё скрипт на мининг
Posted: 2005-02-17 11:29:18
скрипт на мининг с поганой ходилкой ставим на антимеджик зон дома
сундук кладём туда реколы кладём рядом прилоченную рунку в шахту
кладём в бекпак рунку к сундуку даём чару лопату перекрученную черенком на West и запускаем скрипт если кого заинтересовало могу
оформить надлежайшим образом поменять ходилку раскоментировать и т д
ходилка тут интелектуальная задаёш одну троэкторию он совсем по другой ходит
сундук кладём туда реколы кладём рядом прилоченную рунку в шахту
кладём в бекпак рунку к сундуку даём чару лопату перекрученную черенком на West и запускаем скрипт если кого заинтересовало могу
оформить надлежайшим образом поменять ходилку раскоментировать и т д
Code: Select all
sub main()
beremrecoll()
end sub
sub eemain()
var Container='0x401A2BEC'
while UO.Life>0
wait(1000)
CheckLag()
mining()
gotoxy(uo.getx()+4,uo.gety()-4)
wait(1000)
CheckLag()
mining()
gotoxy(uo.getx()-4,uo.gety()-4)
wait(1000)
CheckLag()
mining()
gotoxy(uo.getx()-4,uo.gety()+4)
wait(1000)
CheckLag()
mining()
gotoxy(uo.getx()+4,uo.gety()+4)
wait(1000)
CheckLag()
mining()
wend
end sub
sub pereklad()
var Container='0x4015D94C'
UO.FindType('0x19B9')
while not UO.GetQuantity('finditem')==0
UO.MoveItem('finditem','0','0x4015D94C')
wait(500)
CheckLag()
UO.FindType('0x19B9')
wend
UO.FindType('0x19BA')
while not UO.GetQuantity('finditem')==0
UO.MoveItem('finditem','0','0x4015D94C')
wait(500)
CheckLag()
UO.FindType('0x19BA')
wend
UO.FindType('0x19B8')
while not UO.GetQuantity('finditem')==0
UO.MoveItem('finditem','0','0x4015D94C')
wait(500)
CheckLag()
UO.FindType('0x19B8')
wend
UO.FindType('0x19B7')
while not UO.GetQuantity('finditem')==0
UO.MoveItem('finditem','0','0x4015D94C')
wait(500)
CheckLag()
UO.FindType('0x19B7')
wend
beremrecoll()
end sub
sub beremrecoll()
var exit =0
var Container='0x4015D94C'
UO.FindType('0x1F4C','0x0000','backpack')
If UO.GetQuantity('finditem')>0 Then
CheckLag()
UO.MoveItem('finditem','10','Container')
endif
wait(500)
UO.FindType('0x1F4C','0x0000',Container)
If UO.GetQuantity('finditem')>0 Then
CheckLag()
UO.MoveItem('finditem','4','backpack')
endif
recollvshaxtu()
end sub
sub recolldomoi()
repeat
uo.print('...')
CheckLag()
uo.deletejournal()
uo.waittargetobject('0x402FDD77')
uo.usetype('0x1F4C')
wait(5000)
until not UO.InJournal('The spell fizzles')and not UO.InJournal('sufficient mana for this spell')
pereklad()
end sub
sub recollvshaxtu()
repeat
uo.print('...')
CheckLag()
uo.deletejournal()
uo.waittargetobject('0x402FDC3F')
uo.usetype('0x1F4C')
wait(5000)
until not UO.InJournal('The spell fizzles')and not UO.InJournal('sufficient mana for this spell')
eemain()
end sub
sub mining()
var mx, my, mz, i, j
var ismining, ixx, isheavy
mx = UO.GetX("self")
my = UO.GetY("self")
mz = UO.GetZ("self")
UO.DeleteJournal()
for i = mx-3 to mx+3
for j = my -3 to my+3
UO.Print("Now Mining In: "+str(mx-i)+" "+str(my-j))
ismining =1
while not UO.InJournal("no ore here") and not UO.InJournal("location") and not UO.InJournal("far away") and not UO.InJournal("in rock") and ismining
UO.DeleteJournal()
UO.Waittargettile("1341", str(i), str(j), str(mz))
UO.Usetype('0x0f3a')
if UO.Weight>250 then
recolldomoi()
Return
endif
ixx = 0
ismining=1
while not UO.InJournal("You put") and not UO.InJournal("location") and not UO.InJournal("no ore") and not UO.InJournal("but fail") and not UO.InJournal("far away") and not UO.InJournal("in rock") and ixx <= 100
wait (1000)
ixx = ixx + 1
wend
if not ismining then
uo.print("Not mining here")
endif
wend
UO.DeleteJournal()
next
next
goto allstop
recolldomoi()
allstop:
uo.print("*** Script ended ***")
end sub
sub gotoXY(x,y)
var myX,myY,lastX=0,lastY=0,i,halt=0,z,r=0
for i=1 to 60
MyX=uo.getX();
MyY=uo.getY();
if LastX==MyX AND LastY==MyY then
halt=halt+1
else
halt=0
end if
if halt>=10 then
if uo.GetDir()==1 then
for z=0 to 8
uo.press(40)
next
end if
if uo.GetDir()==3 then
for z=0 to 8
uo.press(37)
next
end if
if uo.GetDir()==5 then
for z=0 to 8
uo.press(3)
next
end if
if uo.GetDir()==7 then
for z=0 to 8
uo.press(39)
next
end if
halt=15
end if
if abs(x-myX)<=1 AND abs(y-myY)<=2 then
return 1
end if
if x<=MyX then
if y<=MyY then
for z=0 to 3
uo.press(3)
next
else
for z=0 to 3
uo.press(37)
next
end if
else
if y<=MyY then
for z=0 to 3
uo.press(39)
next
else
for z=0 to 3
uo.press(40)
next
end if
end if
lastX=myX
lastY=myY
wait(200)
next
return 0
end sub
sub abs(num)
if num>=0 then
return num
else
return num*(-1)
end if
end sub
SUB CheckLag() ; Copyright from YOKO forum.
UO.DeleteJournal()
UO.Click('backpack')
repeat
wait(100)
until UO.InJournal('backpack')
END SUB
ходилка тут интелектуальная задаёш одну троэкторию он совсем по другой ходит