Page 1 of 1

Помогите исправит скрипт на плавку.

Posted: 2006-05-22 17:59:07
by quinta
sub plavka()
var k,m
var cont='0x401D6117'
dim ings[4]
ings[0]='0x19B7'
ings[1]='0x19BA'
ings[2]='0x19B8'
ings[3]='0x19B9'
uo.useobject(cont)
uo.findtype('0x19B9','0x0000','backpack')
uo.moveitem('finditem','all',cont)
wait(500)
uo.findtype('-1','-1',cont)
while uo.GetQuantity('finditem')>1
uo.moveitem('finditem','2','backpack')
wait(300)
uo.findtype('0x19BA','0x0000','backpack')
k=uo.getserial('finditem')
uo.waittargetobject(k)
uo.usefromground('0x1983')
wait(500)
for m=0 to 3
uo.findtype(ings[m],'0x0000','backpack')
if uo.findcount()>0 then
uo.moveitem('finditem','all',cont)
wait(700)
endif
wait(50)
next
uo.findtype('-1','-1',cont)
wend
endsub


Кому не трудно исправьте его на плавку отмычек по той же схеме - кладет все отмычки в сумку, потом выкладывает по одной в пак и сразу плавит.

Заранее очень благодарен.

Posted: 2006-05-22 19:03:09
by Scripts Writer

Code: Select all

sub plavka() 
var lockpick=' type '
var k,m 
var cont='0x401D6117' 
dim ings[4] 
ings[0]='0x19B7' 
ings[1]='0x19BA' 
ings[2]='0x19B8' 
ings[3]='0x19B9' 
uo.useobject(cont) 
uo.findtype(lockpick,'0x0000','backpack') 
uo.moveitem('finditem','all',cont) 
wait(500) 
uo.findtype('-1','-1',cont) 
while uo.GetQuantity('finditem')>1 
uo.moveitem('finditem','2','backpack') 
wait(300) 
uo.findtype(lockpick,'0x0000','backpack') 
k=uo.getserial('finditem') 
uo.waittargetobject(k) 
uo.usefromground('0x1983') 
wait(500) 
for m=0 to 3 
uo.findtype(ings[m],'0x0000','backpack') 
if uo.findcount()>0 then 
uo.moveitem('finditem','all',cont) 
wait(700) 
endif 
wait(50) 
next 
uo.findtype('-1','-1',cont) 
wend 
endsub 
Вставь в переменную lockpick =' тип отмычек ' и вперёд с песней.

Posted: 2006-05-22 19:13:46
by quinta
Поставил, он кладет отмычки в заданный мешек но потом отключается.

Posted: 2006-05-22 19:22:49
by Grin

Code: Select all

sub plavka() 
	var lockpick=' type ' 
	var k,m 
	var cont='0x401D6117' 
	dim ings[4] 
	ings[0]='0x19B7' 
	ings[1]='0x19BA' 
	ings[2]='0x19B8' 
	ings[3]='0x19B9' 
		uo.useobject(cont) 
		uo.findtype(lockpick,'-1','backpack') 
		uo.moveitem('finditem','all',cont) 
		wait(500)
		uo.findtype(lockpick,'-1',cont) 
		while uo.GetQuantity('finditem')>1 
			uo.moveitem('finditem','2','backpack') 
			wait(300) 
			uo.findtype(lockpick,'-1','backpack') 
			uo.waittargetobject('finditem') 
			uo.usefromground('0x1983') 
			wait(500) 
			for m=0 to 3 
				uo.findtype(ings[m],'-1','backpack') 
				if uo.findcount()>0 then 
					uo.moveitem('finditem','all',cont) 
					wait(700) 
				endif 
				wait(50) 
			next 
			uo.findtype(lockpick,'-1',cont) 
		wend 
endsub

Posted: 2006-05-22 19:29:13
by quinta
Работает, спасибо вам большое!!!