Yoko

All sides of Injection
It is currently 2025-10-15 06:28:57

All times are UTC+02:00




Post new topic  Reply to topic  [ 2 posts ] 
Author Message
PostPosted: 2011-01-30 10:52:14 
Offline

Joined: 2008-12-19 17:32:13
Posts: 3
Подскажите плиз игшраю на олмере не могу запустить скрипт на рубку . Чар загружает коардинаты подходит к дереву встаёт в хайд и всё на этом


sub lolo()
var in_file = file("C:\records.txt")
Dim treeX[100],treeY[100],treeZ[100],treeT[100]
Var TreeCount, i, k

var msg_finish = 'полезная древесина кончилась'
var msg_fail = 'никуда не годятся'
var tAxe = '0x0F47'

uo.print('Загружаем координаты из файла...')
in_file.open()
TreeCount=safe call in_file.readNumber()
for i = 1 to TreeCount
treeT[i]=safe call in_file.ReadNumber()
treeX[i]=safe call in_file.ReadNumber()
treeY[i]=safe call in_file.ReadNumber()
treeZ[i]=safe call in_file.ReadNumber()
next
in_file.close()

repeat
for i = 1 to TreeCount
gotoXY(treeX[i],treeY[i])
repeat
k = 0
CheckHidden()
CheckLag()
uo.DeleteJournal()
uo.Print(STR(treeT[i]) + " " + STR(treeX[i]) + " " + STR(treeY[i]) + " " + STR(treeZ[i]))
uo.WaitTargetTile(treeT[i],treeX[i],treeY[i],uo.GetZ('self'))
uo.UseType(tAxe)
repeat
wait(500)
k = k + 1
until uo.InJournal(msg_finish) || uo.InJournal(msg_fail) || (k>200)
until uo.InJournal(msg_finish)
next
uo.Print('Обход деревьев окончен. Ожидаем респ.')
WaitForResp()
until uo.Dead()
end sub

Sub CheckHidden()
Var k
if not uo.Hidden() then
repeat
k = 0
uo.WarMode(0)
uo.DeleteJournal()
uo.UseSkill('Hiding')
uo.Print('Прячемся...')
repeat
wait(100)
k = k + 1
until uo.Hidden() || uo.InJournal('обнаружены') || (k>50)
until uo.Hidden()
uo.Print('Спрятались.')
endif
endsub

Sub WaitForResp()
wait(300000)
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 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( 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 abs(num)
if num>=0 then
return num
else
return num*(-1)
end if
end sub

sub CheckLag()
UO.DeleteJournal()
UO.Click('backpack')

Repeat
wait(200)
Until UO.InJournal('backpack')
end sub


Top
   
PostPosted: 2011-01-30 14:04:16 
Offline
User avatar

Joined: 2009-05-28 09:58:28
Posts: 2802
Location: Иваново
Потому что там жестокий антимакрос :twisted:
Чеж вы все пытаетесь убить неплохие сервера своими ботами ?

_________________
Image
YokoInjection CodeSweeper
Ошибка "Unhandled exception in parser"
Стрелялка для олдов.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 2 posts ] 

All times are UTC+02:00


Who is online

Users browsing this forum: Bing [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited