Yoko

All sides of Injection
It is currently 2024-03-28 21:14:55

All times are UTC+02:00




Post new topic  Reply to topic  [ 5 posts ] 
Author Message
PostPosted: 2018-11-15 17:00:55 
Offline

Joined: 2018-11-15 16:55:28
Posts: 3
Привет, не подскажете почему не работает данный скрипт на новой инже? На старых версиях все нормально лутает.. А на 2015 после резки трупа отказывается с пола юзаться..
При чем если просто кинуть на пол, и попробовать залутать скриптом - все нормально, но если именно порезать труп - то не лутает.
Nmy wrote:
Code:
sub corpser()
   uo.waittargetobject('lastcorpse')
   uo.usetype('0x0F51')
   wait(500)
   Lootground()
   sword()
endsub
sub Lootground()
   VAR n, f
   VAR Torso=uo.objatlayer('Torso')
   VAR Legs=uo.objatlayer('Legs')
   VAR Arms=uo.objatlayer('Arms')
   VAR Gloves=uo.objatlayer('Gloves')
   VAR Hat=uo.objatlayer('Hat')
   VAR Neck=uo.objatlayer('Neck')
   VAR Lhand=uo.objatlayer('Lhand')
   
   Dim Loot[40]
   Loot[1]='0x204E' ; Shroud
   Loot[2]='0x20D6' ; Dragon
   Loot[3]='0x0F5E' ; broadsword
   Loot[4]='0x143A' ; maul
   Loot[5]='0x13B9' ; Viking Sword
   Loot[6]='0x0F60' ; longsword
   Loot[7]='0x0F62' ; Spear
   Loot[8]='0x0E87' ; Pitchfork   
   Loot[9]='0x143E' ; Halberd
   Loot[10]='0x0F4D' ; Bardiche
   Loot[11]='0x0F45' ; Executioner's Axe
   Loot[12]='0x0F4B' ; double axe
   Loot[13]='0x13FA' ; Despise
   Loot[14]='0x13B1' ; Bow
   Loot[15]='0x0F4F' ; Heavy Crossbow
   Loot[16]='0x13FC' ; Crossbow
   Loot[17]='0x1086' ; Braclet
   Loot[18]='0x0EED' ; Gold Coin
   Loot[19]='0x13BF' ; chainmail tunic
   Loot[20]='0x13BE' ; chainmail leg
   
   Dim armor[12]
   armor[1]='0x1B77'  ; Heater Sheild
   armor[2]='0x1B76'  ; Heater Sheild
   armor[3]='0x1415'  ; Plate Mail
   armor[4]='0x1416'  ; Plate Mail
   armor[5]='0x141A'  ; Platemail Legs
   armor[6]='0x1411'  ; Platemail Legs
   armor[7]='0x1418'  ; Platemail Gauntlets
   armor[8]='0x1414'  ; Platemail Gauntlets
   armor[9]='0x1410'  ; Platemail Arms
   armor[10]='0x1419' ; Platemail Helm
   armor[11]='0x1412' ; Platemail Helm
   armor[12]='0x1413' ; Platemail Gorget
   
   for n=1 to 12
      if uo.countground(armor[n]) then
         uo.usefromground(armor[n])
         wait(50)
         f=1
      endif
   next
   for n=1 to 20
      if uo.countground(Loot[n]) then
         uo.moveitem('~'+Loot[n],0,'backpack')
         wait(700)
      endif
   next
   if f==1 then
      if Torso<>'' then
         uo.useobject(Torso)
      endif
      if Legs<>'' then
         uo.useobject(Legs)
      endif
      if Arms<>'' then
         uo.useobject(Arms)
      endif
      if Gloves<>'' then
         uo.useobject(Gloves)
      endif
      if Hat<>'' then
         uo.useobject(Hat)
      endif
      if Neck<>'' then
         uo.useobject(Neck)
      endif
      if Lhand<>'' then
         uo.equip('Lhand',Lhand)
      endif
   endif
   uo.print(' -= done =- ')
endsub


Top
   
PostPosted: 2018-11-17 09:23:54 
Offline
User avatar

Joined: 2009-05-28 09:58:28
Posts: 2802
Location: Иваново
Это не совсем лут. Это собиралка брони с земли брони и одевание на себя.

Лутает только с земли

Quote:
for n=1 to 20
if uo.countground(Loot[n]) then
uo.moveitem('~'+Loot[n],0,'backpack')
wait(700)
endif
next

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


Top
   
PostPosted: 2018-11-21 17:07:52 
Offline

Joined: 2018-11-15 16:55:28
Posts: 3
Mirage wrote:
Это не совсем лут. Это собиралка брони с земли брони и одевание на себя.

Лутает только с земли

Quote:
for n=1 to 20
if uo.countground(Loot[n]) then
uo.moveitem('~'+Loot[n],0,'backpack')
wait(700)
endif
next

Оно часть лутает, а другая часть юзается и тем самым моментально цепляется на себя. На новой инже не работает это, на старой все отлично.
Вот именно юзание
Code:
   for n=1 to 12
      if uo.countground(armor[n]) then
         uo.usefromground(armor[n])
         wait(50)
         f=1
      endif
   next


Top
   
PostPosted: 2018-11-26 22:41:39 
Offline
User avatar

Joined: 2009-05-28 09:58:28
Posts: 2802
Location: Иваново
На новом парни перелопатили много процедур. Какие то старые перестали работать ввиду старости. Можно чуть длинше расписать без countground и usefromground и будет гуд.

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


Top
   
PostPosted: 2018-11-30 07:00:49 
Offline

Joined: 2016-06-27 23:40:13
Posts: 2
Mirage wrote:
На новом парни перелопатили много процедур. Какие то старые перестали работать ввиду старости. Можно чуть длинше расписать без countground и usefromground и будет гуд.

Мираж, вот пытаюсь с этим вопросом разобраться. Залез в файлик Injection.chm и эти процедуры (countground и usefromground) вполне себе там есть, даже с описанием. А проблема скрипта в том что он не находит появившейся после разделки трупа лут на земле (лут валяется в 1 тайле). Так вот для теста я ручками лут просто перенес на соседние тайлы (ну считай пошевелил) и запустил скрипт повторно - вуаля, все нашел на земле и поднял. та же самая проблема с finditem('findtype') или как его там, он не находит вещи на земле именно после резки трупа.
Может ли такое быть что при резке - лут падает на какую то непонятную координату по высоте (для данной версии инжекта), то есть мб это можно как то учесть диапазоном? (что бы он искал там от -2 до +2 по высоте)
Для примера:
Code:
sub LootTest()
   
   DIM loot[9]
   
   loot[0]='0x0EED' ; GP
   loot[1]='0x0F78' ; Batwings
   loot[2]='0x0F91' ; Wyrm's Hearts
   loot[3]='0x0F3F' ; Arrows
   loot[4]='0x0F81' ; Fertile Dirt
   loot[5]='0x0F7E' ; Bones
   loot[6]='0x0F82' ; Dragons Blood
   loot[7]='0x0F8F' ; Volcanic Ash
   loot[8]='0x0F8E' ; Serpents Scales
   
   var i
   uo.set('finddistance','2')
   for i = 0 to 8
      uo.FindType(loot[i],'-1','ground')
      if uo.FindCount() then
         uo.MoveItem('finditem')
         wait(750)
      end if
      wait(50)
   next
end sub

работает на поднятие с земли золота и регов только после их "шевеления"
Буду благодарен за любую консультацию.


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

All times are UTC+02:00


Who is online

Users browsing this forum: No registered users and 23 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