Yoko

All sides of Injection
It is currently 2025-10-19 06:13:56

All times are UTC+02:00




Post new topic  Reply to topic  [ 4 posts ] 
Author Message
PostPosted: 2009-09-14 11:58:09 
Offline

Joined: 2007-11-21 00:15:38
Posts: 9
Сделал скрипт на автоподбор указанных вещей с пола в радиусе 2х клеток.

Code:
sub Looting()
uo.exec("set finddistance 2")
var l
var a
dim LootingItem[10]
LootingItem[0] = 0x09B0
LootingItem[1] = 0x183D
LootingItem[2] = 0x182C
LootingItem[3] = 0x183B
LootingItem[4] = 0x1831
LootingItem[5] = 0x183E
LootingItem[6] = 0x0E76
LootingItem[7] = 0x0E21
LootingItem[8] = 0x183D
LootingItem[9] = 0x204E
LootingItem[10] = 0x0DE1
for l=0 to 10
uo.findtype(LootingItem[l],-1,"ground")
if uo.FindCount()>0 and uo.GetDistance("finditem")<=3 then
uo.Grab(-1,"finditem")
a=uo.getserial("finditem")
uo.print(a)
end if
next
end sub


так же пробовал писать ограничение так: uo.set('finddistance','2')

Но скрипт все равно ищет всё в приделах экрана.
Не подскажите, как сделать?


Top
   
 Post subject:
PostPosted: 2009-09-14 12:08:29 
Offline
Expert!
User avatar

Joined: 2005-09-14 15:31:58
Posts: 2152
Location: Latvia
Code:
sub Looting() 
uo.set('finddistance','2')
var l
var a
dim LootingItem[10]
LootingItem[0] = '0x09B0'
LootingItem[1] = '0x183D'
LootingItem[2] = '0x182C'
LootingItem[3] = '0x183B'
LootingItem[4] = '0x1831'
LootingItem[5] = '0x183E'
LootingItem[6] = '0x0E76'
LootingItem[7] = '0x0E21'
LootingItem[8] = '0x183D'
LootingItem[9] = '0x204E'
LootingItem[10] = '0x0DE1'
for l=0 to 10
uo.findtype(LootingItem[l],-1,'ground')
if uo.FindCount() then
uo.moveitem('finditem',0,'backpack')
a=uo.getserial("finditem")
uo.print(a)
end if
next
end sub

_________________
Уроки языка Injection
Основные команды языка Injection
Yoko Injection Code Sweeper
Drw (2009) скрипты
2017 Начал играть на Uorpg.net


Last edited by Nmy on 2009-09-15 11:16:21, edited 2 times in total.

Top
   
 Post subject:
PostPosted: 2009-09-14 18:50:49 
Offline
User avatar

Joined: 2009-05-28 09:58:28
Posts: 2802
Location: Иваново
типы лучше заключить в кавычки

_________________
Image
YokoInjection CodeSweeper
Ошибка "Unhandled exception in parser"
Стрелялка для олдов.


Top
   
 Post subject:
PostPosted: 2009-09-15 11:16:49 
Offline
Expert!
User avatar

Joined: 2005-09-14 15:31:58
Posts: 2152
Location: Latvia
Mirage wrote:
типы лучше заключить в кавычки


незаметил :oops:

_________________
Уроки языка Injection
Основные команды языка Injection
Yoko Injection Code Sweeper
Drw (2009) скрипты
2017 Начал играть на Uorpg.net


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

All times are UTC+02:00


Who is online

Users browsing this forum: No registered users and 1 guest


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