Yoko

All sides of Injection
It is currently 2026-01-19 05:25:53

All times are UTC+02:00




Post new topic  Reply to topic  [ 13 posts ] 
Author Message
PostPosted: 2008-07-17 10:07:16 
Offline
User avatar

Joined: 2008-07-13 23:17:10
Posts: 15
Положение: есть поле, поле больше, ручки сразу до всего не дотягиваються, тянуться только на 4 клетки!

дальше два варианта:

Code:
sub main() 
uo.set('finddistance','4')
repeat
UO.Findtype('0x1A99','-1','ground')
uo.usefromground(0x1A99)
wait(400)
until false
endsub


Все хорошо, но
Code:
uo.set('finddistance','4') 

Похоже не дает условие для
uo.usefromground('type')

Как поступить?

Вариант дЫва:

Образ перебора тайлов:
Code:
Sub main()
VAR x, y, t, k

for y=-2 to 2
   for x=-2 to 2
      k = 0
      repeat
         UO.DeleteJournal()
         t = UO.Timer()
         k = k + 1
         UO.CancelTarget()
         wait(300)
         UO.WaitTargetTile( TileNum, STR( UO.GetX() + x ), STR( UO.GetY() + y ), 0)
   UO.UseType('type'); если так или uo.usefromgroud('T') всеравно пытаеться дотянуться до недоступных тайлов
         repeat
            wait(300)
         until false
endsub


Возможноли просто обусловить Дабл клик по тайлу.

Заранее огромное спасибо за внимание!


Top
   
 Post subject:
PostPosted: 2008-07-17 10:25:22 
Offline

Joined: 2005-04-19 18:00:29
Posts: 2259
Location: Московская область
Если у растения есть тип, то

Code:
sub Get_Herb()
  var type=
 
  uo.Set('finddistance','4')
  while not uo.Dead()
    uo.FindType(type,'-1','ground')
    if uo.FindCount() then
      uo.UseObject('finditem')
      wait(350)
    else
      wait(100)
    end if
  wend
end sub     
   


Top
   
 Post subject:
PostPosted: 2008-07-17 10:56:42 
Offline
User avatar

Joined: 2008-07-13 23:17:10
Posts: 15
Да, в теории здорво... но он почему то всеравно хочед дотянуться до недоступных тайлов =(


Top
   
 Post subject:
PostPosted: 2008-07-17 11:59:10 
Offline
Junior Expert
User avatar

Joined: 2004-06-24 22:08:56
Posts: 3220
uo.Set('finddistance','0') тада )

_________________
YokoInjection CodeSweeper
Function not found?
Possession of mathematics at the level of art - a gift that is only available for election.
Sorry for my clumsy English.
Skype: d119060


Top
   
 Post subject:
PostPosted: 2008-07-17 15:18:18 
Offline
User avatar

Joined: 2008-07-13 23:17:10
Posts: 15
Это неприемлимо раз, и два, разницы мало!

Как сделать что бы он "атачил тайл"? просто дабл клик на заданый тайл


Top
   
 Post subject:
PostPosted: 2008-07-17 15:42:35 
Offline
User avatar

Joined: 2005-04-04 18:23:12
Posts: 187
Есть вот такая штука http://yoko.com.ua/help/help.php?lang=r ... targettile , но сомневаюсь, что прокатит.

А вобще-то Скриптс Врайтер показал правильный скрипт, поиграйся с дистанцией, попробуй выставить 2, 3, 5..


Top
   
 Post subject:
PostPosted: 2008-07-17 16:35:29 
Offline
User avatar

Joined: 2008-07-13 23:17:10
Posts: 15
ну я пробывал по всякому её менять... ноль эмоций, всеравно думает, что у него руки резиновые!

Code:
uo.waittargettile(lasttile/tilenum,[x],[y],[z])


Здорво, но он просто устанавливает ловушку... а далее следующий "Use'type'" пытаеться удленнить руки!


Top
   
 Post subject:
PostPosted: 2008-07-17 17:02:39 
Offline

Joined: 2005-04-19 18:00:29
Posts: 2259
Location: Московская область
Игнорируй


Top
   
 Post subject:
PostPosted: 2008-07-17 17:18:07 
Offline
User avatar

Joined: 2008-07-13 23:17:10
Posts: 15
Ага, вот это уже интересней, а как игнорировать все что выходит за дистанцию определенную? Конкретно кусок кода, пожалуйста, если можно!


Top
   
 Post subject:
PostPosted: 2008-07-17 17:21:58 
Offline
User avatar

Joined: 2005-04-04 18:23:12
Posts: 187
uo.Set('finddistance','4') ;)
Всё, что дальше - игнорируеться.


Top
   
 Post subject:
PostPosted: 2008-07-17 17:42:22 
Offline

Joined: 2005-04-19 18:00:29
Posts: 2259
Location: Московская область
Code:
uo.Ignore('finditem')


Top
   
 Post subject:
PostPosted: 2008-07-17 20:37:32 
Offline
User avatar

Joined: 2008-07-13 23:17:10
Posts: 15
Purgen wrote:
uo.Set('finddistance','4') ;)
Всё, что дальше - игнорируеться.


Должна игнорироваться! Но не игнорируеться!

Scripts Writer wrote:
Code:
uo.Ignore('finditem')


Эт я знал... но конкретно допустим к следующему коду как привязать?

ЗЫ. вот родил код... но что то он даже не пытаеться потыкать в цвяточки:

Code:
sub main()
uo.set('finddistance','4')
var xlop='0x1A9B'
var xlop2='0x1A9C'
var cnt
uo.findtype(xlop,-1,'ground')
cnt=uo.findcount()
while cnt>0
uo.findtype(xlop,-1,'ground')
cnt=uo.findcount()
uo.useobject('Finditem')
wait(400)
uo.findtype(xlop2,-1,'ground')
if uo.findcount() then
uo.grab(0,'finditem')
wait(666)
endif
wend
end sub


Top
   
 Post subject:
PostPosted: 2008-07-17 21:36:17 
Offline
Expert!
User avatar

Joined: 2006-02-07 08:51:40
Posts: 1348
Location: г. Старый Оскол
Попробуй увеличить задержку.


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

All times are UTC+02:00


Who is online

Users browsing this forum: No registered users 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:  
cron
Powered by phpBB® Forum Software © phpBB Limited