
Копал сначала на пилоте, а потом сразу на стэлс

Moderators: Murderator+, Murderator
Code: Select all
sub FISHING()
DIM ULOVtype[7]
ULOVtype[0] = '0x09CC' #fish1
ULOVtype[1] = '0x09CD' #fish2
ULOVtype[2] = '0x09CE' #fish3
ULOVtype[3] = '0x09CF' #fish4
ULOVtype[4] = 'UUF' #heal
ULOVtype[5] = 'DMF' #ball
ULOVtype[6] = 'RVH' #sos Tattered Treasure map
VAR udochka = 'XHF'
VAR nozh = '0x0F51'
VAR NumTile = '6043'
VAR MaxWeigth = UO.STR*4
VAR i, x, y, k
wait(200)
UO.Equipt('Rhand', udochka)
start:
for x=-6 to 6
for y=-6 to 6
UO.Print("??????? ? ?????: " + str(x) + " " + str(y))
UO.DeleteJournal()
while not UO.InJournal("no fish here") and not UO.InJournal("location") and not UO.InJournal("far away") and not UO.InJournal("in water")and not UO.InJournal("Try fishing elsewhere")
k = 0
if UO.Weight > MaxWeigth then
goto finish
endif
UO.DeleteJournal()
UO.WaitTargetTile(NumTile, str(UO.GetX()+x), str(UO.GetY()+y), str(UO.GetZ()))
UO.UseType(udochka)
while not (UO.InJournal("in water") or UO.InJournal("far away") or UO.InJournal("but fail") or UO.InJournal("You pull") or UO.InJournal("no fish here") or UO.InJournal("location") or k==50)
k = k + 1
wait(100)
if UO.InJournal("Targeting Cancelled") then
goto start
endif
wend
#???????? ????
if UO.InJournal("You put") then
for i=0 to 6
UO.FindType(ULOVtype[i], '-1', 'ground')
UO.MoveItem('finditem')
wait(50)
next
endif
wend
next
next
finish:
UO.Print("?????? ???????????? ??? ?????")
wait(1000)
#????? ????
UO.Print("????? ???? ?? ??? ??????")
for i=0 to 3
UO.WaitTargetType(ULOVtype[i])
UO.UseType(nozh)
wait(1000)
next
if UO.Weight < MaxWeigth-5 then
goto start
endif
UO.Print("??????? ???????????")
endsub
Code: Select all
sub fishing()
var mx, my, mz, i, j
uo.print('? ??? ??????')
uo.exec('addobject Bag')
while uo.targeting()
wait(100)
wend
mx = UO.GetX("self")
my = UO.GetY("self")
mz = UO.GetZ("self")
UO.DeleteJournal()
for i = mx-4 to mx+4
for j = my -4 to my+4
if UO.dead() then
return
endif
UO.Print("Now Fishing In: "+str(mx-i)+" "+str(my-j))
while not UO.InJournal("no fish here") and not UO.InJournal("location") and not UO.InJournal("far away") and not UO.InJournal("in water")
UO.DeleteJournal()
UO.Waittargettile("1341", str(i), str(j), str(mz))
UO.Usetype("0x0DBF") ;FishingPole
if UO.dead() then
return
endif
if UO.Weight>660 then
return
endif
while not UO.InJournal("You pull") and not UO.InJournal("location") and not UO.InJournal("no fish") and not UO.InJournal("but fail") and not UO.InJournal("far away") and not UO.InJournal("in water")
wait (100)
if UO.InJournal("You pull") then
UO.SetReceivingContainer('Bag')
UO.findtype('0x09CC','0x0000','ground') ;fish
UO.grab ('3','finditem')
wait (500)
UO.findtype('0x09CD','0x0000','ground') ;fish
UO.grab ('3','finditem')
wait (500)
UO.findtype('0x09CE','0x0000','ground') ;fish
UO.grab ('3','finditem')
wait (500)
UO.findtype('0x09CF','0x0000','ground') ;fish
UO.grab ('3','finditem')
wait (500)
UO.findtype('0x14EB','0x09B1','ground') ;tattered map
UO.grab ('1','finditem')
wait (500)
UO.findtype('0x09CC','0x0487','ground') ;Truly rare fish
UO.grab ('1','finditem')
wait (500)
UO.findtype('0x09CC','0x0445','ground') ;Prize fish
UO.grab ('1','finditem')
wait (500)
UO.UnSetReceivingContainer()
end if
wend
wend
UO.DeleteJournal()
next
next
end sub