| Yoko http://forum.yoko.com.ua/ |
|
| мининг помоги те дописать некотырые функции http://forum.yoko.com.ua/viewtopic.php?f=20&t=6442 |
Page 1 of 1 |
| Author: | Ready [ 2006-02-27 14:19:10 ] |
| Post subject: | мининг помоги те дописать некотырые функции |
sub main() var run1 = '0x400021AB' var run2 = '0x4000315E' var run3 = '0x400069EE' var run4 = '0x4000D4EF' var run5 = '0x4000D5C8' while not uo.dead() digrune(run1,4,4) digrune(run2,4,4) digrune(run3,4,4) digrune(run4,4,4) digrune(run5,4,4) wend end sub sub digrune(rune,dx,dy) var r,x,y,x1,y1,x2,y2 var bord,nx,ny,stpx=1,stpy=1 x=uo.getx() y=uo.gety() while uo.getx()==x and uo.gety()==y uo.cast("Recall",rune) wait(10000) wend x=uo.getx() y=uo.gety() x1=x-dx y1=y-dy x2=x+dx y2=y+dy gotoxy(x1+2*stpx,y1+2*stpy,0) gotoxy(x1,y1,2) for y=y1 to y2 step stpy for x=x1 to x2 step stpx bord=0 nx=x ny=y if uo.weight>uo.str*4 then unloadr(rune) end if r=dig(x,y) if r==0 then gotoxy(x1/2+x2/2,y1/2+y2/2,2) end if next next unloadr("") end sub sub dig(x,y) var i hide() uo.track("1",str(x),str(y)) gotoxy(x,y,2) uo.deletejournal() while not uo.injournal("put the") and not uo.injournal("no ore here") and not uo.injournal("far away") and not uo.injournal("line of sight") and not uo.injournal("mining in rock") if uo.waiting() then uo.canceltarget() end if uo.deletejournal() uo.waittargettile("1440",str(x),str(y),"0") uo.usetype("NPF") wait(1000) for i=0 to 50 wait(100) if uo.injournal("put the") or uo.injournal("fail to") or uo.injournal("no ore here") or uo.injournal("line of sight") or uo.injournal("mining in rock") then i=50 end if next wend if uo.injournal("no ore here") then i=1 else i=0 end if uo.findtype("0x19B9","0","backpack") if uo.findcount() then #uo.exec("moveitem finditem 1 ground "+str(x)+" "+str(y)+" 0") end if return i end sub sub unloadc(container) uo.canceltarget() uo.ignorereset() uo.findtype("-1","-1","backpack") while uo.findcount() uo.print(str(uo.findcount())+" left") if (uo.getgraphic("finditem")<>"0x0EED" and uo.getgraphic("finditem")<>"0x0E76" and uo.getgraphic("finditem")<>"0x1769" and uo.getgraphic("finditem")<>"0x176B" and uo.getgraphic("finditem")<>"0x0EFA") or uo.getquantity("finditem")>1 then uo.moveitem("finditem","-1",container) wait(1200) end if uo.ignore("finditem") uo.findtype("-1","-1","backpack") wend end sub sub unloadr(rune) var i=0 while uo.getx()<>1318 or uo.gety()<>953 uo.cast("Recall","0x400005C2") wait(10000) wend unloadc("0x40005FC7") if rune<>"" then while uo.getx()==1318 and uo.gety()==953 uo.cast("Recall",rune) while uo.getx()==1318 and uo.gety()==953 and i<50 wait(1200) wend wend end if end sub sub gotoxy(x,y,prec) var ld=0,ldc=0 var dx,dy var mx,my var ox,oy,mk,k uo.print(">") uo.track("1",str(x),str(y)) start: mx=UO.GetX() my=UO.GetY() dx=mx-x if dx<0 then dx=0-dx endif dy=my-y if dy<0 then dy=0-dy endif if dy>dx then dx=dy end if if dx<=prec then return end if if not ldc then uo.print(STR(dx)) end if if dx<3 then mk=70 else mk=15 end if ox=mx oy=my for k=1 to mk mx=UO.GetX() my=UO.GetY() if mx<>ox or my<>oy then goto sdidapl end if wait(10) next sdidapl: mx=UO.GetX() my=UO.GetY() dx=mx-x if dx<0 then dx=0-dx endif dy=my-y if dy<0 then dy=0-dy endif if dy>dx then dx=dy end if if dx<=prec then return end if if ld==dx then ldc=ldc+1 if ldc>20 then uo.print("Can not reach location!") return end if else ld=dx end if if mx==x then if my==y then return endif if my>y then #UO.Print("UR") UO.Press(33) goto start endif #UO.Print("DL") UO.Press(35) goto start end if if mx<x then if my>y then #UO.Print("R") UO.Press(39) goto start endif if my==y then #UO.Print("DR") UO.Press(34) goto start endif #UO.Print("D") UO.Press(40) goto start end if if my<y then #UO.Print("L") UO.Press(37) goto start endif if my==y then #UO.Print("LU") UO.Press(36) goto start endif #UO.Print("U") UO.Press(38) goto start end sub sub hide() while NOT UO.Hidden() UO.DeleteJournal() UO.UseSkill('Hiding') repeat wait(100) until UO.InJournal('You have hidden') OR UO.InJournal('seem to hide') wend wait(100) end sub sub pk() UO.DeleteJournal() while True if UO.InJournal(":") and not UO.InJournal("Zeppellin:") and not UO.InJournal("Elemental:") and not UO.InJournal("Orn:") and not UO.InJournal("Zostrich:") and not UO.InJournal("Horse:") and not UO.InJournal("Llama:") and not UO.InJournal("Ostard:") and not UO.InJournal("Mustang:") then UO.Exec("terminate main") UO.Warmode("0") wait(100) UO.WaitTargetObject('0x4001A04E') UO.cast('Recall') wait(60000) UO.Exec("exec main") Return endif wait(500) wend end sub при виде любого игроко кушал инвизку и выжимал рекол на базу и ждал там 30 миннут после чего продолжнал всё по новой |
|
| Author: | Blood Slayer [ 2006-02-27 20:13:47 ] |
| Post subject: | |
Какойто не читабельный скрипт ... ( для меня ) Думаю чтоб реколилься от людей можно сделать так Code: sub PK() А вообще лудше у грамотных людей узнать ... |
|
| Page 1 of 1 | All times are UTC+02:00 |
| Powered by phpBB® Forum Software © phpBB Limited https://www.phpbb.com/ |
|