Yoko

All sides of Injection
It is currently 2025-12-21 17:43:12

All times are UTC+02:00




Post new topic  Reply to topic  [ 5 posts ] 
Author Message
PostPosted: 2005-10-06 22:16:51 
Offline

Joined: 2004-12-13 01:27:00
Posts: 190
Code:
sub fix()
var dx=uo.getx('lasttarget'),dy=uo.gety('lasttarget')

uo.print(STR(uo.getX('self')))
uo.print(STR(uo.getY('self')))

uo.findtype('0x0F36','-1','my') #Type of item 4fix
if uo.FindCount() then

uo.waittargetobject('finditem')

if uo.getx('lasttarget')>uo.getx('self') then
uo.print('Fixed!')
uo.print('Fixed!')
dx=uo.getx('lasttarget')
dx=dx+1
#dy=dy-1
endif

if uo.getx('lasttarget')<uo.getx('self') then
uo.print('Fixed!')
uo.print('Fixed!')
dx=uo.getx('lasttarget')
dx=dx-1
#dy=dy+1
endif

if uo.gety('lasttarget')<uo.gety('self') then
uo.print('Fixed!')
uo.print('Fixed!')
dy=uo.gety('lasttarget')
dy=dy-1
#dx=dx+1
endif


if uo.gety('lasttarget')>uo.gety('self') then
uo.print('Fixed!')
uo.print('Fixed!')
dy=uo.getY('lasttarget')
dy=dy+1
#dx=dx-1
endif

uo.drop('0',STR(dx),STR(dy),STR(uo.getY('lasttarget')))

uo.print(STR(dx)+" "+STR(dy))
wait(100)
uo.canceltarget()
uo.set('lasttarget','laststatus')

endif

end sub


Етот скрипт кидает айтем зади врага, исходя из ваших координат, но почему то скрипт либо не рабоатет иногда, либо кидает на "большую высоту"


Top
   
 Post subject:
PostPosted: 2005-10-07 00:21:33 
Offline
Junior Expert
User avatar

Joined: 2004-06-24 22:08:56
Posts: 3220
Code:
uo.drop('0',STR(dx),STR(dy),STR(uo.getY('lasttarget'))) 

Code:
uo.drop('0',STR(dx),STR(dy),STR(uo.getZ('lasttarget'))) 


Top
   
 Post subject:
PostPosted: 2005-10-07 19:34:54 
Offline

Joined: 2004-12-13 01:27:00
Posts: 190
спасибо.
Но еще есть вопросы:
1. Почему цель выдается на айтем, когда у нас есть строка определяющяя, что кидать.
2. Почему после блокировки, пропадает таргет с обьекта и его сново приходится искать в толпе?


Top
   
 Post subject:
PostPosted: 2005-10-08 13:48:40 
Offline

Joined: 2004-12-13 01:27:00
Posts: 190
непонятки Щ_Щ
ап


Top
   
 Post subject:
PostPosted: 2005-10-08 18:59:29 
Offline
Expert!
User avatar

Joined: 2005-04-23 10:19:43
Posts: 388
В самом начале сделай:
var Enemy=UO.GetSerial("laststatus")
И дальше юзай переменную Enemy, она никуда не пропадет. А разные глобальные указатели очень не постоянные.


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 8 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:  
Powered by phpBB® Forum Software © phpBB Limited