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

Бс.
http://forum.yoko.com.ua/viewtopic.php?f=20&t=8020
Page 1 of 1

Author:  klonuk [ 2006-06-20 08:33:29 ]
Post subject:  Бс.

Code:
sub BS2222() 
VAR meshok='0x0E76'
Var Type='0x1BEF'
Var Color='0x0000'
VAR meshok2
var a=0
VAR sunduk='0x40009AD8'
var sunduk2='0x40009ED6'


UO.UnSetCatchBag(sunduk2)
wait(300)
UO.FindType( 'meshok', '-1', 'sunduk2')
   UO.Grab('1','finditem')
   meshok2=UO.GetSerial('finditem')
a=0
UO.SetCatchBag(meshok2)
wait(1000)
UO.MoveItem( 'finditem', '1', 'sunduk2' )

repeat
repeat
 if UO.Count(Type,Color)<20 then
        cheklag()
        UO.FindType(Type,Color,'sunduk')
        UO.Grab('300','finditem')
        wait(2000)
  else
           uo.Print('Èíãè êîí÷èëèñü')
           wait(1000)
           Paused()
 endif
cheklag()
UO.FindType(Type, Color, 2)
uo.exec("recall finditem 3")
wait(1500)
UO.LClick(492,455)
wait(1500)
UO.LClick(492,455)
UO.DeleteJournal()
while not (UO.InJournal("You put") or UO.InJournal("You have failed"))
wait(300)
wend
if UO.InJournal("You put") then
   a=a+1
endif

wait(1000)
cheklag()
 UO.FindType('0x1B73')

if UO.FindCount() > 0  then
   UO.MoveItem( 'finditem', '1', 'meshok2' )
   wait(1000)
endif
 
if a==200 then
 Dobor()
endif

until uo.Dead()
end sub

sub Dobor()
VAR meshok='0x0E76'
VAR meshok2
var sunduk2='0x40009ED6 '

UO.UnSetCatchBag()
wait(300)
UO.FindType( meshok, -1, sunduk2 )
   UO.Grab('finditem')
UO.SetCatchBag(meshok2)
wait(1000)
UO.MoveItem( 'finditem', '1', 'sunduk2' )

end sub




Написал скрипт.
Моя задача.
1.берет мешок дает ему имя кидает обрано в сундук
2.кует и кидает в этот мешок
3.когда итемов болше 200 берет еше 1 дает имя и по кругу
Запуталься ,скрипт не работает творит все что угодно кроме того что надо, прошу помощи чайник уже просто не варит....Ошибки прошу обьяснить я на чинающий скриптер чтобы их не допускать в будуещем. :roll:

Author:  klonuk [ 2006-06-21 10:02:06 ]
Post subject: 

Ну профи откликнетесь ... не охота забрасывать скрипт.

Author:  klonuk [ 2006-06-22 13:54:27 ]
Post subject: 

Грин хоть ты помаги ведь это по твоей части олдп =)) и дк

Author:  Grin [ 2006-06-22 14:30:30 ]
Post subject: 

Code:
sub BS2222() 
VAR meshok='0x0E76'
Var Type='0x1BEF'
Var Color='0x0000'
VAR meshok2
var a=0
VAR sunduk='0x40009AD8'
var sunduk2='0x40009ED6'


UO.UnSetCatchBag()
wait(300)
UO.FindType( meshok, '-1', sunduk2)
   UO.Grab('1','finditem')
   meshok2=UO.GetSerial('finditem')
a=0
UO.SetCatchBag(meshok2)
wait(1000)
UO.MoveItem( 'finditem', '1', 'sunduk2' )

repeat
repeat
 if UO.Count(Type,Color)<20 then
        cheklag()
        UO.FindType(Type,Color,sunduk)
        UO.Grab('300','finditem')
        wait(2000)
  else
           uo.Print('Eiae eii?eeenu')
           wait(1000)
           Paused()
 endif
cheklag()
UO.FindType(Type, Color)
uo.recall('finditem', 3)
wait(1500)
UO.LClick(492,455)
wait(1500)
UO.LClick(492,455)
UO.DeleteJournal()
while not (UO.InJournal("You put") or UO.InJournal("You have failed"))
wait(300)
wend
if UO.InJournal("You put") then
   a=a+1
endif

wait(1000)
cheklag()
 UO.FindType('0x1B73')

if UO.FindCount() > 0  then
   UO.MoveItem( 'finditem', '1', meshok2)
   wait(1000)
endif
 
if a==200 then
 Dobor()
endif

until uo.Dead()
end sub

sub Dobor()
VAR meshok='0x0E76'
VAR meshok2
var sunduk2='0x40009ED6 '

UO.UnSetCatchBag()
wait(300)
UO.FindType( meshok, -1, sunduk2 )
   UO.Grab('finditem')
UO.SetCatchBag(meshok2)
wait(1000)
UO.MoveItem( 'finditem', '1', sunduk2)

end sub

Author:  klonuk [ 2006-06-22 15:19:09 ]
Post subject: 

респект....... скрипт настроин работает на ура.... осталось чуток изменений

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