Yoko

All sides of Injection
It is currently 2024-03-28 10:46:15

All times are UTC+02:00




Post new topic  Reply to topic  [ 6 posts ] 
Author Message
PostPosted: 2013-03-07 01:36:07 
Offline
User avatar

Joined: 2012-03-20 00:32:06
Posts: 243
Location: РФ, г. Москва
Вот скрипт, полность рабочий с модернизацией, раньше просто делал фул и всё, щас делает и складывае в мешок
можно ли исправить его и добавить чтоб он работал пока не кончатся инги в сундуке
сам скрипт
Code:
######################################################
###              Делаем фулл с щитом               ###
######################################################
var Tbag = '0x0E76'  ; Тип сумок для разгрузки мап если вы укажыте тип бланк мап.
var Exit=0, Dbag, LastTimer
var Cont='0x404B775E'
var Sunduk='0x404B775E'
var ingots='0x1BEF'
var katana='0x13FE'
var flag ; Ставим все свое

sub Full()
    var n, a, k, color, name
    uo.addobject('ingi')
    while uo.targeting()
        wait(500)
    wend
    color=uo.getcolor('ingi')
    name=getname('ingi')
   
    Dim full[7]
    full[1]='Plate Helm'
    full[2]='Platemail Gorget'
    full[3]='Platemail Gauntlets'
    full[4]='Platemail Arms'
    full[5]='Platemail Legs'
    full[6]='Platemail (25 '
    full[7]='Heater Shield'
    for n=1 to 7
        repeat
            uo.cancelmenu()
            uo.automenu('Blacksmithing','Colored Armor & Weapons')
            uo.automenu('Colored Armor & Weapons',name+' Armor')
            uo.automenu(name+' Armor',name+' Plate Armor & Shields')
            uo.automenu(name+' Plate Armor & Shields',name+' '+full[n])
            checklag()
            uo.useobject('ingi')
            repeat
                wait(400)
            until uo.injournal('You have failed|You put the')
        until uo.injournal('You put the')
    next
    uo.print(' Done')
    Fullsklad()
end sub

sub getname(ingi)
    var n, c, t
    Dim name[27]
    name[1]=''
    name[2]='Rusty'
    name[3]='Old Copper'
    name[4]='Dull Copper'
    name[5]='Bronze'
    name[6]='Shadow'
    name[7]='Rose'
    name[8]='Agapite'
    name[9]='Blood Rock'
    name[10]='Verite'
    name[11]='Valorite'
    name[12]='Mytheril'
    name[13]='Black Rock'
    name[14]='Obsidian'
    name[15]='Plutonium'
    name[16]='Vulcan'
    name[17]='Aqua'
    name[18]='Eldar'
    name[19]='Elvin'
    name[20]='Acid'
    name[21]='Steel'
    name[22]='Sand Rock'
    name[23]='Blood Crest'
    name[24]='Gorgan'
    name[25]='Krynite'
    name[26]='Crystaline'
    name[27]='Dragon'
   
    Dim col[27]
    col[1]='0x0000'
    col[2]='0x0750'
    col[3]='0x0590'
    col[4]='0x060A'
    col[5]='0x0488'
    col[6]='0x096B'
    col[7]='0x0014'
    col[8]='0x0193'
    col[9]='0x04C2'
    col[10]='0x07D5'
    col[11]='0x00CE'
    col[12]='0x052D'
    col[13]='0x0455'
    col[14]='0x0028'
    col[15]='0x08AF'
    col[16]='0x09DA'
    col[17]='0x0060'
    col[18]='0x0BA7'
    col[19]='0x09E6'
    col[20]='0x09B9'
    col[21]='0x09D3'
    col[22]='0x008F'
    col[23]='0x09EC'
    col[24]='0x09F0'
    col[25]='0x010F'
    col[26]='0x09A4'
    col[27]='0x0085'
   
    Dim typ[3]
    typ[1]='0x1BE3'
    typ[2]='0x1BF5'
    typ[3]='0x1BE9'
   
    Dim nam[3]
    nam[1]='Copper'
    nam[2]='Silver'
    nam[3]='Golden'
   
    t=uo.getgraphic(ingi)
    c=uo.getcolor(ingi)
    for n=1 to 3
        if typ[n]==t then
            return nam[n]
        endif
    next
    for n=2 to 27
        if col[n]==c then
            return name[n]
        endif
    next
endsub

sub CheckLag()
    repeat
        UO.DeleteJournal()
        UO.Click('backpack')
    until backpack()==1
endsub

sub backpack()
    var n
    for n=0 to 200
        if uo.injournal('a backpack') then
            return 1
        endif
        wait(200)
    next
endsub

sub Fullsklad()
    var l
    var i=0, name, telo
    uo.print('Начинаем складывать фуллы')
    dim Loot[7]
    Loot[1] = 0x1412 ; голова
    Loot[2] = 0x1413 ; шея
    Loot[3] = 0x1410 ; плечи
    Loot[4] = 0x1414 ; перчатки
    Loot[5] = 0x1415 ; пузо
    Loot[6] = 0x1411 ; ноги
    Loot[7] = 0x1B76 ; щит
   
    repeat
        i=0
        for l = 1 to 7
            GetBag()
            uo.findtype(Loot[l], -1, 'backpack')
            if uo.findcount() then
                telo = UO.GetSerial('finditem')
                UO.Click(telo)
                name = UO.GetName(telo)
                wait(540)
                uo.print("Положено "+str(1+i)+" частей."+uo.GetName('finditem')+"")
                uo.moveitem('finditem',-1,Dbag)
                i=i+1
            end if
        next
        CheckDbag()
        uo.print('ВСЁ!!!')
    until uo.dead()
end sub

sub GetBag()
    flag=0
    repeat
        uo.findtype(Tbag,-1,Sunduk)
        if uo.findcount() then
            Dbag=uo.getserial('finditem')
            Open(Dbag)
            uo.findtype(-1,-1,Dbag)
            if uo.findcount()>6 then
                uo.ignore(Dbag)
            else
                flag=1
            endif
        endif
    until flag==1
endsub

sub CheckDbag()
    uo.findtype(-1,-1,Dbag)
    if uo.findcount()>6 then
        uo.ignore(Dbag)
        GetBag()
    endif
endsub

sub checklag()
    repeat
        UO.DeleteJournal()
        UO.Click('backpack')
    until backpack()==1
endsub

sub backpack()
    var n
    for n=0 to 200
        if uo.injournal('a backpack') then
            return 1
        endif
        wait(200)
    next
endsub

sub Open(what)
    uo.useobject(what)
    checklag()
    wait(800)
endsub

_________________
Не быть жадным - уже богатство, не быть расточительным – доход.
TylllKaH
YokoInjection CodeSweeper
Ошибка "Unhandled exception in parser"


Top
   
PostPosted: 2013-03-07 01:45:32 
Offline
User avatar

Joined: 2006-12-08 10:51:50
Posts: 718
Location: Москва
можно! :mrgreen: нужно накатать прoцедуру, в которой будет производиться добор ингов и запуск full. где у тебя трудности?


Last edited by ZeroDX on 2013-03-07 07:05:45, edited 1 time in total.

Top
   
PostPosted: 2013-03-07 02:14:34 
Offline
User avatar

Joined: 2012-03-20 00:32:06
Posts: 243
Location: РФ, г. Москва
трудность в том что инги разных цветов и из 17 имеют 3 типа все типы и цвета могу скинуть, я просто не знаю как прописывать такое меню
Code:
    Dim name[27]
    name[1]=''
    name[2]='Rusty'
    name[3]='Old Copper'
    name[4]='Dull Copper'
    name[5]='Bronze'
    name[6]='Shadow'
    name[7]='Rose'
    name[8]='Agapite'
    name[9]='Blood Rock'
    name[10]='Verite'
    name[11]='Valorite'
    name[12]='Mytheril'
    name[13]='Black Rock'
    name[14]='Obsidian'
    name[15]='Plutonium'
    name[16]='Vulcan'
    name[17]='Aqua'
    name[18]='Eldar'
    name[19]='Elvin'
    name[20]='Acid'
    name[21]='Steel'
    name[22]='Sand Rock'
    name[23]='Blood Crest'
    name[24]='Gorgan'
    name[25]='Krynite'
    name[26]='Crystaline'
    name[27]='Dragon'

_________________
Не быть жадным - уже богатство, не быть расточительным – доход.
TylllKaH
YokoInjection CodeSweeper
Ошибка "Unhandled exception in parser"


Top
   
PostPosted: 2013-03-07 07:18:56 
Offline
User avatar

Joined: 2006-12-08 10:51:50
Posts: 718
Location: Москва
с меню можно как с журналом, можно обрывок названия использовать, без имён цветов


Top
   
PostPosted: 2013-03-08 01:00:10 
Offline
User avatar

Joined: 2012-03-20 00:32:06
Posts: 243
Location: РФ, г. Москва
хотя стоп, как мне зделать чтоб он добирал только тн инги которые я указад, чтоб он из них делал фулы?

_________________
Не быть жадным - уже богатство, не быть расточительным – доход.
TylllKaH
YokoInjection CodeSweeper
Ошибка "Unhandled exception in parser"


Top
   
PostPosted: 2013-03-08 01:05:33 
Offline
User avatar

Joined: 2006-12-08 10:51:50
Posts: 718
Location: Москва
ставь uo.addobject('ingots'), потом запоминай их цвет и тип uo.getcolor('ingots'), uo.getgraphic('ingot') и только с ними и взаимодействуй


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

All times are UTC+02:00


Who is online

Users browsing this forum: No registered users and 13 guests


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