Yoko
http://forum.yoko.com.ua/

Фильтр для AutoLoota
http://forum.yoko.com.ua/viewtopic.php?f=17&t=16904
Page 1 of 1

Author:  rezident [ 2012-02-18 14:20:33 ]
Post subject:  Фильтр для AutoLoota

Вообщем юзаю этот отличный пылесос

возник вопрос можно ли заблокировать какие-то итемы в поиске?

нашел только скрипты которые лутают определенный шмот, но это не подходит.
Nmy wrote:
Code:
sub Lootall()
   var n, corpse   
   if (uo.getserial('backpack') <> uo.getserial('lastcontainer')) then
      uo.ignorereset()
      corpse=uo.getserial('lastcontainer')
      uo.findtype(-1,-1,corpse)
      while uo.findcount()
         n=uo.getserial('finditem')
         uo.moveitem('finditem',0,'backpack')
         uo.print(' item '+str(uo.findcount()))
         checklag()
         wait(600)
         uo.findtype(-1,-1,corpse)
         if uo.findcount() then
            if n==uo.getserial('finditem') then
               uo.ignore('finditem')
               uo.findtype(-1,-1,corpse)
            endif
         endif
      wend
   endif
   uo.print(' -= Done =- ')
endsub

Author:  rezident [ 2012-02-18 17:15:24 ]
Post subject:  Re: Фильтр для AutoLoota

и еще 1 вопрос) можно как-то дописать чтоб оно лутало в контейнер X, а не в общую сумку.

Author:  ZeroDX [ 2012-02-18 17:28:25 ]
Post subject:  Re: Фильтр для AutoLoota

Code:
sub Lootall()
    var n = 0, ok, corpse, i, container = '0x12345678'    ; Контейнер-приемник
    dim ignore[4]                                          ;  Общее кол-во элементов в массиве
    ignore[0] = '0x1234'
    ignore[1] = '0x1234'
    ignore[2] = '0x1234'
    ignore[3] = '0x1234'    
    if uo.getserial(container) <> uo.getserial('lastcontainer') and uo.getserial('backpack') <> uo.getserial('lastcontainer') then
        uo.ignorereset()
        corpse=uo.getserial('lastcontainer')
        uo.findtype(-1,-1,corpse)
        repeat
            uo.findtype(-1,-1,corpse)
            if uo.findcount() then
                ok = 1
                for i = 0 to 3                                ; Общее кол-во элементов в массиве минус один
                    if uo.getgraphic('finditem') == ignore[i] then
                        ok = 0
                    endif
                next
                if n==uo.getserial('finditem') or not ok then
                    uo.ignore('finditem')
                else
                    n=uo.getserial('finditem')
                    uo.moveitem('finditem',0,container)
                    uo.print(' item '+str(uo.findcount()))
                    checklag()
                    wait(600)
                endif
            endif
        until not uo.findcount()
    endif
    uo.print(' -= Done =- ')
endsub

Author:  rezident [ 2012-02-18 20:01:21 ]
Post subject:  Re: Фильтр для AutoLoota

Line 16: Variable undefined - I

Вот как изменил

sub Lootall()
var n = 0, ok = 1, corpse, container = '0x401247C9' ; Контейнер-приемник
dim ignore[4] ; Общее кол-во элементов в массиве
ignore[0] = '0x144F' ; bone armor
ignore[1] = '0x1452' ; bone legs
ignore[2] = '0x1451' ; bone helmet
ignore[3] = '0x144E' ; bone arms
if uo.getserial(container) <> uo.getserial('lastcontainer') and uo.getserial('backpack') <> uo.getserial('lastcontainer') then
uo.ignorereset()
corpse=uo.getserial('lastcontainer')
uo.findtype(-1,-1,corpse)
repeat
uo.findtype(-1,-1,corpse)
if uo.findcount() then
for i = 0 to 3 ; Общее кол-во элементов в массиве минус один
if uo.getgraphic('finditem') == ignore[i] then
ok = 0
endif
next
if n==uo.getserial('finditem') or not ok then
uo.ignore('finditem')
else
n=uo.getserial('finditem')
uo.moveitem('finditem',0,container)
uo.print(' item '+str(uo.findcount()))
checklag()
wait(600)
endif
endif
until not uo.findcount()
endif
uo.print(' -= Done =- ')
endsub

Author:  ZeroDX [ 2012-02-18 22:12:09 ]
Post subject:  Re: Фильтр для AutoLoota

обновил пост со скриптом. изменение только во 2-ой строке
Code:
var n = 0, ok = 1, corpse, i, container = '0x12345678'    ; Контейнер-приемник

Code:
dim ignore[4] ; Общее кол-во элементов в массиве
 ignore[0] = '0x144F' ; bone armor
 ignore[1] = '0x1452' ; bone legs
 ignore[2] = '0x1451' ; bone helmet
 ignore[3] = '0x144E' ; bone arms

Ты можешь добавить или убавить строки.

Author:  rezident [ 2012-02-18 23:01:08 ]
Post subject:  Re: Фильтр для AutoLoota

это я понял) я так для теста 4 оставил)
и сюда
Quote:
for i = 0 to 3 ; Общее кол-во элементов в массиве минус один
(х-1) вставить как я понял

Author:  rezident [ 2012-02-19 13:51:23 ]
Post subject:  Re: Фильтр для AutoLoota

вообщем не работает) так как он доходит до заигнориной шмотки и перестает лутать все остальное.

Author:  Mirage [ 2012-02-19 14:17:03 ]
Post subject:  Re: Фильтр для AutoLoota

поиск не работает?

Author:  ZeroDX [ 2012-02-19 15:02:46 ]
Post subject:  Re: Фильтр для AutoLoota

rezident wrote:
вообщем не работает) так как он доходит до заигнориной шмотки и перестает лутать все остальное.

исправил

Author:  Mirage [ 2012-02-19 20:20:30 ]
Post subject:  Re: Фильтр для AutoLoota

n=uo.getserial('finditem')
Строка не нужна. Масло масленое.

Author:  rezident [ 2012-02-20 15:18:38 ]
Post subject:  Re: Фильтр для AutoLoota

ZeroDX wrote:
rezident wrote:
вообщем не работает) так как он доходит до заигнориной шмотки и перестает лутать все остальное.

исправил

спс
отлично работает)

Author:  rezident [ 2012-02-20 15:19:51 ]
Post subject:  Re: Фильтр для AutoLoota

Mirage wrote:

в твоем скрипте очень много того что мне не нужно) а так как я пока слаб в правлении скриптов) мне сложно будет изменить твой скрипт под себя

Author:  ZeroDX [ 2012-02-20 16:33:08 ]
Post subject:  Re: Фильтр для AutoLoota

Mirage wrote:

:P :P :P :P :P

Author:  Mirage [ 2012-02-20 18:41:40 ]
Post subject:  Re: Фильтр для AutoLoota

ну вот а я там так расписывал :|

Page 1 of 1 All times are UTC+02:00
Powered by phpBB® Forum Software © phpBB Limited
https://www.phpbb.com/