Page 1 of 1

помощь СПаринг (подправка)

Posted: 2006-03-31 12:24:55
by ghost_hnt

Code: Select all

sub WarTraining() 
var x = uo.getX() 
var y = uo.getY() 
var tx, ty 
uo.addObject('opponent') 
while uo.targeting() 
wait(200) 
wend 
uo.addObject('bandages') 
while uo.targeting() 
wait(200) 
wend 
uo.addObject('weapon') 
while uo.targeting() 
wait(200) 
wend
uo.addObject('shield') 
while uo.targeting() 
wait(200) 
wend 

if uo.getX() > uo.getX('opponent') then 
tx = x+1 
ty = y 
else 
if uo.getX('opponent') > uo.getX() then 
tx = x-1 
ty = y 
else 
if uo.getY() > uo.getY('opponent') then 
tx = x 
ty = y+1 
else 
if uo.getY('opponent') > uo.getY() then 
tx = x 
ty = y-1 
else 
uo.print('Вы должны быть на расстоянии!!') 
return 
endif 
endif 
endif 
endif 
uo.warmode(true) 
uo.attack('opponent') 
repeat 
if uo.getHP() < uo.getMaxHP()/2 then 
Walk(tx,ty) 
uo.warmode(false) 
repeat 
if uo.stamina <30 then
uo.usetype('0x0F0B') #рефрешка
endif
uo.waittargetobject('self') 
uo.usetype(uo.getGraphic('bandages')) 
wait(6500) 
until uo.getHP() == uo.getMaxHP() 
uo.useobject('weapon')
wait(700) 
uo.useobject('shield')
wait(200) 
Walk(x,y) 
uo.warmode(true) 
uo.attack('opponent') 
endif 
if uo.getHP('opponent') < uo.getMaxHP('opponent')/2 then 
Walk(tx,ty) 
uo.warmode(false) 
repeat 
uo.waittargetobject('opponent') 
uo.usetype(uo.getGraphic('bandages')) 
wait(6500) 
until UO.InJournal('Do you wanna make a mummy?')
uo.useobject('weapon')
wait(500) 
uo.useobject('shield')
wait(200) 
Walk(x,y) 
uo.warmode(true) 
uo.attack('opponent') 
endif 
wait(700) 
until uo.dead() 
endsub 
if uo.stamina < 30 then
uo.usetype('0x0F0B') #рефрешка
endif

sub Walk(x,y) 
go: 
while not uo.getX() == x || not uo.getY() == y 
if not uo.getX() == x then 
if uo.getX() > x then 
uo.press(36) 
else 
uo.press(34) 
endif 
endif 
if not uo.getY() == y && uo.getX() == x then 
if uo.getY() > y then 
uo.press(33) 
else 
uo.press(35) 
endif 
endif 
checklag() 
wend 
checklag() 
if not uo.getX() == x || not uo.getY() == y then 
goto go 
endif 
endsub 

sub CheckLag() 
if uo.Waiting()>0 then 
uo.Exec('canceltarget') 
end if 
uo.DeleteJournal() 
uo.Click('backpack') 
repeat 
wait(50) 
until uo.InJournal('backpack') 
while uo.injournal('backpack') 
uo.setJournalLine(uo.Injournal('backpack')-1,'is Empty!') 
wend 
end sub
вот непомню чей скрипт с моей подработкой!!
но хз почему не берется ЩИТ* пишет:
the item should be eqiupped to use
если ставишь сначало чтобы брал щит, а потом оружие, пишет тоже самое
ПОМОГИТЕ ПОЖАЛУЙСТА :!: :!:

Re: помощь СПаринг (подправка)

Posted: 2006-03-31 12:44:39
by Kynep
ghost_hnt wrote: вот непомню чей скрипт с моей подработкой!!
но хз почему не берется ЩИТ* пишет:
the item should be eqiupped to use
если ставишь сначало чтобы брал щит, а потом оружие, пишет тоже самое
ПОМОГИТЕ ПОЖАЛУЙСТА :!: :!:
Вот пробуй:

Code: Select all

sub WarTraining() 
var x = uo.getX() 
var y = uo.getY() 
var tx, ty 
uo.addObject('opponent') 
while uo.targeting() 
wait(200) 
wend 
uo.addObject('bandages') 
while uo.targeting() 
wait(200) 
wend 

uo.setarm('temp1')

if uo.getX() > uo.getX('opponent') then 
tx = x+1 
ty = y 
else 
if uo.getX('opponent') > uo.getX() then 
tx = x-1 
ty = y 
else 
if uo.getY() > uo.getY('opponent') then 
tx = x 
ty = y+1 
else 
if uo.getY('opponent') > uo.getY() then 
tx = x 
ty = y-1 
else 
uo.print('Вы должны быть на расстоянии!!') 
return 
endif 
endif 
endif 
endif 
uo.warmode(true) 
uo.attack('opponent') 
repeat 
if uo.getHP() < uo.getMaxHP()/2 then 
Walk(tx,ty) 
uo.warmode(false) 
repeat 
if uo.stamina <30 then
uo.usetype('0x0F0B') #рефрешка
endif
wait(100)
uo.waittargetobject('self') 
uo.usetype(uo.getGraphic('bandages')) 
wait(6500) 
until uo.getHP() == uo.getMaxHP() 
uo.arm('temp1')
wait(1000) 
Walk(x,y) 
uo.warmode(true) 
uo.attack('opponent') 
endif 
if uo.getHP('opponent') < uo.getMaxHP('opponent')/2 then 
Walk(tx,ty) 
uo.warmode(false) 
repeat 
uo.waittargetobject('opponent') 
uo.usetype(uo.getGraphic('bandages')) 
wait(6500) 
until UO.InJournal('Do you wanna make a mummy?')
uo.arm('temp1')
wait(1000) 
Walk(x,y) 
uo.warmode(true) 
uo.attack('opponent') 
endif 
wait(700) 
until uo.dead() 
endsub 
if uo.stamina < 30 then
uo.usetype('0x0F0B') #рефрешка
endif

sub Walk(x,y) 
go: 
while not uo.getX() == x || not uo.getY() == y 
if not uo.getX() == x then 
if uo.getX() > x then 
uo.press(36) 
else 
uo.press(34) 
endif 
endif 
if not uo.getY() == y && uo.getX() == x then 
if uo.getY() > y then 
uo.press(33) 
else 
uo.press(35) 
endif 
endif 
checklag() 
wend 
checklag() 
if not uo.getX() == x || not uo.getY() == y then 
goto go 
endif 
endsub 

sub CheckLag() 
if uo.Waiting()>0 then 
uo.Exec('canceltarget') 
end if 
uo.DeleteJournal() 
uo.Click('backpack') 
repeat 
wait(50) 
until uo.InJournal('backpack') 
while uo.injournal('backpack') 
uo.setJournalLine(uo.Injournal('backpack')-1,'is Empty!') 
wend 
end sub

Posted: 2006-03-31 13:16:01
by ghost_hnt
не ни фига не пашет лучше ккак было чтобы выбрать щит оружие и т.д(удобнее)
мож попробовать uo.usetype или как-то так* :?:

Posted: 2006-03-31 13:19:38
by Kynep
ghost_hnt wrote:не ни фига не пашет лучше ккак было чтобы выбрать щит оружие и т.д(удобнее)
мож попробовать uo.usetype или как-то так* :?:
Че не пашет, у мя все пашет

Posted: 2006-03-31 13:33:59
by Destruction
И у меня пашет - иначе я бы после написания его бы не выложил :!:

Posted: 2006-03-31 13:47:33
by ghost_hnt
Cooper wrote:
ghost_hnt wrote:не ни фига не пашет лучше ккак было чтобы выбрать щит оружие и т.д(удобнее)
мож попробовать uo.usetype или как-то так* :?:
Че не пашет, у мя все пашет
погоди объясни:
я запускаю этот скрипт беру в руки щит и молоток:
после того как он отхеливает, он набегает и не берет в руки вообще ничего (бьет кулаками) :?

Posted: 2006-03-31 13:52:56
by Kynep
ghost_hnt wrote:
Cooper wrote:
ghost_hnt wrote:не ни фига не пашет лучше ккак было чтобы выбрать щит оружие и т.д(удобнее)
мож попробовать uo.usetype или как-то так* :?:
Че не пашет, у мя все пашет
погоди объясни:
я запускаю этот скрипт беру в руки щит и молоток:
после того как он отхеливает, он набегает и не берет в руки вообще ничего (бьет кулаками) :?
Мля сорь, исправил, смотри выше

Posted: 2006-04-01 18:39:52
by ghost_hnt
млин все равно берет только оружие, но терь пишет
weapon armed
you put shield in your pack :x

Posted: 2006-04-01 18:49:01
by Grin
возсожно слишком быстро одевает
поробуй
,set dressdelay 300

Posted: 2006-04-01 21:20:50
by ghost_hnt
Grin wrote:возсожно слишком быстро одевает
поробуй
,set dressdelay 300
куда это вставить?)

Posted: 2006-04-01 22:41:26
by Kynep
ghost_hnt wrote:
Grin wrote:возсожно слишком быстро одевает
поробуй
,set dressdelay 300
куда это вставить?)
Никуда, просто в клиенте набери