мля, ваще ща че-то не пашет...
объеденил скрипт омыча и вот этот:
http://forum.yoko.com.ua/viewtopic.php?t=7829
Code: # ****************************************************** # *** Injection 505.18 ************************ Jikus ** # ****************************************************** sub main() ; + EDIT +++++++++++++++++++++++++++++++++++++++++++++++ var zona = 6; ; ++++++++++++++++++++++++++++++++++++++++++++++++++++++ var m, i, a, tr = 1 var tX = UO.GetX('self') var tY = UO.GetY('self') for i=1 to zona if tr then m = - 5 else m = 5 endif for a=1 to zona tY = tY + m GotoXY(tX,tY) Lamber() next tX = tX - 5 if tr then tr = 0 else tr = 1 endif next endsub
sub item() VAR a = 1 # 0 <=> ???????????? ??????? ??????? # 1 <=> ???????????? ??????? ?? ??????? # uo.setglobal('recal', '0') #???????? ?? ???????????? ?? ??????# uo.setglobal('place', '0') #???????? ?? ??????????? ???? ?? ?????# uo.setglobal('circle', '0') #???????? ?? ???????????? ? ????????? ????? ??? ?????? ??????? ?????# uo.setglobal('back', '0') #???????? ?? ????????????? ??????????? ?? ????? ????? ????? ???????# if a == 1 then uo.print('??????? ?????? ? ??????, ???????, ?????????, ???????') uo.exec('addobject Sunduk1') while uo.targeting() wait(100) wend wait(1000) uo.print('??????? ?????? ??? ????') uo.exec('addobject Sunduk2') while uo.targeting() wait(100) wend wait(1000) uo.print('??????? ???? ? ????') uo.exec('addobject Home') while uo.targeting() wait(100) wend wait(1000) uo.print('??????? ???? ? ????? 1') uo.exec('addobject mine1') while uo.targeting() wait(100) wend return endif uo.exec('exec CheckingItems') end sub
sub Lamber() var MaxFailCount = 10, MaxRange = 3, FailCount = 0, LTimer, Tiles, X, Y VAR mx, my, mz, a, b, c, d, e, f while not uo.dead() if uo.injournal('GM') or uo.injournal('Admin') or uo.injournal('Seer') or uo.injournal('Counselor') or uo.injournal('Developer') then uo.usetype('0x0F08') uo.closeuo() else wait(50) endif uo.deletejournal() mx = uo.getx('self') my = uo.gety('self') mz = uo.getz('self') for a = mx-2 to mx+2 for b = my-2 to my+2 while not uo.Hidden() c = 0 uo.warmode('0') uo.useskill('Stealth') repeat wait(100) c = c + 1 until uo.Hidden() or c > 40 wend for Y = MaxRange - ( MaxRange * 2 ) to MaxRange for X = MaxRange - ( MaxRange * 2 ) to MaxRange Tiles = F_HarvestTiles(mX+X, mY+Y) if Tiles then repeat F_DelJournalMine(); LTimer=UO.Timer() UO.WaitTargetTile(Tiles, mX+X, mY+Y, mZ) UO.UseObject("_FSF") repeat wait(100) until UO.InJournal("You put the|useable wood|You can|That is too far away|here to chop") || UO.Timer() > LTimer + 60 || UO.Dead()
if UO.InJournal("That is too far away") then FailCount = FailCount + 1 else FailCount = 0 endif
until UO.InJournal("here to chop|You can|That is too far away") || FailCount >= MaxFailCount || UO.Dead() endif next next ChengePlace() return 0 end sub
sub F_HarvestTiles(X,Y) var i if UO.PrivateGetTile(X, Y, -1, 3274, 3302) then for i=3274 to 3302 if UO.PrivateGetTile(X, Y, -1, i, i) then
; ***** Patch ******************************************** if i==3278 || i==3279 || i==3281 || i==3282 then return 0 endif if i==3284 || i==3285 || i==3287 || i==3289 then return 0 endif if i==3291 || i==3292 || i==3294 || i==3295 then return 0 endif if i==3297 || i==3298 || i==3300 || i==3301 then return 0 endif ; ********************************************************
return i end if next end if return 0 end sub
sub F_DelJournalMine() F_DeleteJournal("You put the") ; F_DeleteJournal("useable wood") ; F_DeleteJournal("That is too far away"); F_DeleteJournal("You can") ; F_DeleteJournal("here to chop") ; end sub
sub F_DeleteJournal( string1 ) var nom = UO.InJournal( string1 ) if nom > 0 then UO.SetJournalLine( Nom - 1, "string replaced" ) F_DeleteJournal( string1 ) endif 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(38) next end if if UO.GetDir()==7 then for z=0 to 8 UO.Press(39) next end if halt=15 end if if Numb(x-myX)<=1 and Numb(y-myY)<=2 then return 1 end if if x<=myX then if y<=myY then for z=0 to 3 UO.Press(38) 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 Numb(num) if num>=0 then return num else return num*(-1) end if end sub
sub ChengePlace() VAR a, b, c, d, e, f, g, h, i, j, k if val(uo.getglobal('circle')) > 3 then uo.setglobal('circle', '1') uo.exec('terminate CheckingPlayers') uo.exec('exec Teleportation') return endif if val(uo.getglobal('circle')) == 1 then if uo.getdir('self') == 3 then a = 1 else a = 2 endif for b = 1 to a uo.press(40) wait(300) next for c = 1 to 3 uo.press(34) wait(300) next for d = 1 to 2 uo.press(39) wait(300) next endif endif if val(uo.getglobal('circle')) == 2 then if uo.getdir('self') == 1 then a = 1 else a = 2 endif for e = 1 to a uo.press(39) wait(300) next for f = 1 to 3 uo.press(33) wait(300) next for g = 1 to 2 uo.press(38) wait(300) next endif if val(uo.getglobal('circle')) == 3 then if uo.getdir('self') == 7 then a = 1 else a = 2 endif for h = 1 to a uo.press(38) wait(300) next for i = 1 to 3 uo.press(36) wait(300) next for j = 1 to 2 uo.press(37) wait(300) next endif k = val(uo.getglobal('circle')) + 1 uo.setglobal('circle', str(k)) uo.exec('exec Lamber') end sub
sub CheckingPlayers() VAR a, b uo.ignore('self', 'on') DIM Chars[2] Chars[0] = '0x0190' #??? ?????? ???????? ????# Chars[1] = '0x0191' #??? ?????? ???????? ????# while not uo.dead() for a = 0 to 1 if uo.injournal('GM') or uo.injournal('Admin') or uo.injournal('Seer') or uo.injournal('Counselor') or uo.injournal('Developer') then uo.usetype('0x0F08') uo.closeuo() else wait(50) endif while val(uo.getglobal('find')) == 1 wait(50) wend uo.set('finddistance', '15') uo.findtype(Chars[a], '-1', '1') if uo.findcount() > 0 then uo.usetype('0x0F08') uo.exec('terminate Teleportation') uo.exec('terminate Obkopka') uo.exec('terminate ChengePlace') uo.exec('exec Teleportation') return else wait(500) endif next wend end sub
sub Teleportation() VAR a, b, c VAR d = uo.getx('self') repeat while uo.mana < 11 uo.warmode('0') uo.useskill('Meditation') wait(1000) wend a = 0 if uo.injournal('GM') or uo.injournal('Admin') or uo.injournal('Seer') or uo.injournal('Counselor') or uo.injournal('Developer') then uo.usetype('0x0F08') uo.closeuo() else wait(50) endif uo.deletejournal() if val(uo.getglobal('recal')) == 1 then uo.waittargetobject('lumb1') uo.cast('Recall') else wait(50) endif repeat wait(100) a = a + 1 until a > 35 or d <> uo.getx('self') or uo.injournal('The spell fizzles.') wait(500) until not uo.injournal('The spell fizzles.') b = val(uo.getglobal('recal')) + 1 uo.setglobal('recal', str(b)) if val(uo.getglobal('recal')) > 23 then uo.setglobal('recal', '1') endif uo.set('finddistance', '7') uo.findtype('0x000E', '-1', '1') #??? ??????????# if uo.findcount() > 0 then uo.usetype('0x0F08') uo.exec('exec Teleportation') return endif if val(uo.getglobal('back')) == 0 then uo.exec('exec CheckingPlayers') uo.setglobal('place', '1') uo.setglobal('circle', '1') uo.exec('exec Obkopka') else uo.setglobal('back', '0') endif end sub
sub GoHome() VAR a, b, c, d, e uo.warmode('0') a = uo.getx('self') repeat while uo.mana < 11 uo.warmode('0') uo.useskill('Meditation') wait(1000) wend if uo.injournal('GM') or uo.injournal('Admin') or uo.injournal('Seer') or uo.injournal('Counselor') or uo.injournal('Developer') then uo.usetype('0x0F08') uo.closeuo() else wait(50) endif b = 0 uo.deletejournal() uo.waittargetobject('Home') uo.cast('Recall') repeat wait(200) b = b + 1 until b > 35 or a <> uo.getx('self') or uo.injournal('The spell fizzles.') until not uo.injournal('The spell fizzles.') for c = 1 to 6 uo.press(33) wait(350) next for d = 1 to 5 uo.press(33) wait(350) next e = val(uo.getglobal('recal')) - 1 uo.setglobal('recal', str(e)) end sub
sub Back() VAR a, b, c, d, e, f, g, h, i, j if val(uo.getglobal('circle')) > 1 then if uo.getdir('self') == 3 then f = 1 else f = 2 endif for a = 1 to f uo.press(40) wait(300) next for b = 1 to 3 uo.press(34) wait(300) next for c = 1 to 2 uo.press(39) wait(300) next endif endif if val(uo.getglobal('circle')) > 2 then if uo.getdir('self') == 1 then f = 1 else f = 2 endif for d = 1 to f uo.press(39) wait(300) next for e = 1 to 3 uo.press(33) wait(300) next for g = 1 to 2 uo.press(38) wait(300) next endif if val(uo.getglobal('circle')) > 3 then if uo.getdir('self') == 7 then f = 1 else f = 2 endif for h = 1 to f uo.press(38) wait(300) next for i = 1 to 3 uo.press(36) wait(300) next for j = 1 to 2 uo.press(37) wait(300) next endif end sub
sub CheckingItems() VAR b uo.findtype('0x0F0E') #??? ?????? ???????# if uo.findcount() > 0 then uo.moveitem('finditem', '-1', 'Sunduk1') wait(1000) checklag() endif DIM Log[2] Log[0] = '0x1BDD' #??? 2?? ? ????? ?????# Log[1] = '0x1BDD' #??? 1?? ????# for var a = 0 to 1 uo.findtype(Log[a]) while uo.findcount() > 0 uo.moveitem('finditem', '-1', 'Sunduk2') wait(1000) checklag() uo.findtype(Ore[a]) wend next uo.useobject('Sunduk1') wait(1000) DIM Reg[3] Reg[0] = '0x0F7A' #Black Pearl# Reg[1] = '0x0F7B' #Bood Moss# Reg[2] = '0x0F86' #Mandrake Root# for b = 0 to 2 if uo.count(Reg[b]) < 22 then uo.findtype(Reg[b], '-1', 'Sunduk1') if uo.findcount() > 0 then uo.moveitem('finditem', '20') wait(1000) checklag() else uo.print('??? ???????????? ?????????? ????? ? ???????') return endif endif next if uo.count('0x0F08') < 5 then #??? ???????# uo.findtype('0x0F08', '-1', 'Sunduk1') if uo.findcount() > 0 then uo.moveitem('finditem', '5') wait(1000) checklag() else uo.print('??? ???????????? ?????????? ??????? ? ???????') ;return endif endif uo.findtype('0x0F43') #??? ???????# while uo.findcount() < 1 uo.findtype('0x0F43', '-1', 'Sunduk1') if uo.findcount() > 0 then uo.moveitem('finditem', '1') else uo.print('??? ???????????? ?????????? ??????? ? ???????') return endif wait(1000) uo.findtype('0x0F43') wend if val(uo.getglobal('back')) == 1 then wait(50) else uo.exec('exec Teleportation') endif end sub
sub Teleportation() VAR a, b, c VAR d = uo.getx('self') repeat while uo.mana < 11 uo.warmode('0') uo.useskill('Meditation') wait(1000) wend a = 0 if uo.injournal('GM') or uo.injournal('Admin') or uo.injournal('Seer') or uo.injournal('Counselor') or uo.injournal('Developer') then uo.usetype('0x0F08') uo.closeuo() else wait(50) endif uo.deletejournal() if val(uo.getglobal('recal')) == 1 then uo.waittargetobject('mine1') uo.cast('Recall') else wait(50) endif repeat wait(100) a = a + 1 until a > 35 or d <> uo.getx('self') or uo.injournal('The spell fizzles.') wait(500) until not uo.injournal('The spell fizzles.') b = val(uo.getglobal('recal')) + 1 uo.setglobal('recal', str(b)) if val(uo.getglobal('recal')) > 23 then uo.setglobal('recal', '1') endif uo.set('finddistance', '7') uo.findtype('0x0008', '-1', '1') #??? ??????????# if uo.findcount() > 0 then uo.usetype('0x0F08') uo.exec('exec Teleportation') return endif if val(uo.getglobal('back')) == 0 then uo.exec('exec CheckingPlayers') uo.setglobal('place', '1') uo.setglobal('circle', '1') uo.exec('exec Lamber') else uo.setglobal('back', '0') endif end sub
|