Yoko

All sides of Injection
It is currently 2025-12-10 13:15:08

All times are UTC+02:00




Post new topic  Reply to topic  [ 12 posts ] 
Author Message
 Post subject: Need help with script
PostPosted: 2007-12-18 06:45:57 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
any ideas how to improve it ?
Code:
sub CheckingPlayers()
VAR a, b
uo.ignore('self', 'on')
DIM Chars[2]
Chars[0] = '0x0190' #boba
Chars[1] = '0x0191' #ciuvas
while not uo.dead()
  for a = 0 to 1 
    while val(uo.getglobal('find')) == 1
      wait(50)
    wend
    uo.set('finddistance', '20')
    uo.findtype(Chars[a], '-1', '1')
    if uo.findcount() > 0 then
       uo.exec('exec recnamo')
      return
    else
      wait(500)
    endif
  next
wend
end sub

Some times it dosent work.. and dont recall.. just stops..
and recnamo()
Code:
sub recnamo()
var a
VAR d = uo.getx('self')
run()
uo.deletejournal()
repeat
   uo.deletejournal()
   uo.waittargetobject('0x4000465D')
   uo.cast('Recall')
   a = 0
    repeat
      wait(100)
      a = a + 1
    until a > 36 or d <> uo.getx('self') or uo.injournal('fizzles')
until not uo.injournal('fizzles')
end sub


Top
   
PostPosted: 2007-12-18 14:23:29 
Offline
User avatar

Joined: 2007-11-01 19:09:30
Posts: 287
Location: Moscow
Mazer wrote:
any ideas how to improve it ?
Code:
sub CheckingPlayers()
VAR a, b
uo.ignorereset # added
uo.ignore('self') # deleted ", 'on'"
DIM Chars[2]
Chars[0] = '0x0190' #boba
Chars[1] = '0x0191' #ciuvas
while not uo.dead()
  for a = 0 to 1
    while val(uo.getglobal('find')) == 1 # can't understand for what is needed
      wait(50)
    wend
    uo.set('finddistance', '20')
    uo.findtype(Chars[a], '-1', 'ground') #replaced '1' to 'ground'
    if uo.findcount('finditem')>0 then
      uo.exec('exec recnamo')
      return
    else
      wait(50) #replaced 500 to 50
    endif
  next
wend
end sub

Some times it dosent work.. and dont recall.. just stops..
and recnamo()
Code:
sub recnamo()
var timec
var myx = uo.getx('self')
var myy=uo.gety('self') #added
#run() #what is that?
repeat
  uo.deletejournal()
  uo.waittargetobject('0x4000465D')
  uo.cast('Recall')
  timec=uo.timer()+80
  while not uo.injournal('fizzles') and not uo.injournal('reagents') and not timec<uo.timer() and (myx==uo.getx('self') and myy==uo.gety('self'))
    wait(50)
  wend
until myx<>uo.getx('self') and myy<>uo.gety('self') # I MADE A MISTAKE HERE! And now i fixed it - char recalls until both xpos and ypos changes
end sub

try that and tell me results

_________________
**Выставляем отступы в скриптах*** ©Destruction
Feel the Power of Dark Side


Last edited by CuHTpoH on 2007-12-18 20:08:55, edited 1 time in total.

Top
   
 Post subject:
PostPosted: 2007-12-18 15:23:00 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
Code:
sub run()
uo.exec('terminate CheckingPlayers')
uo.exec('terminate Checkinglife')
end sub


Top
   
 Post subject:
PostPosted: 2007-12-18 16:50:46 
Offline
User avatar

Joined: 2007-11-01 19:09:30
Posts: 287
Location: Moscow
Does it work or no?

_________________
**Выставляем отступы в скриптах*** ©Destruction

Feel the Power of Dark Side


Top
   
 Post subject:
PostPosted: 2007-12-18 17:04:40 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
recal dosent then it gets to other place it start to recal and recal and recal.. no pause.. 1 second 10 of all regents..


Top
   
 Post subject:
PostPosted: 2007-12-18 17:11:22 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
player serch works with some errors :) fixed one mistake.. and then player recals near me and dont move script cant find it :)


Top
   
 Post subject:
PostPosted: 2007-12-18 20:09:42 
Offline
User avatar

Joined: 2007-11-01 19:09:30
Posts: 287
Location: Moscow
look at my comment about my mistake at the end of the recnamo() script
and about characters find - that is not an error of injection, as i heard UOServer does not send information about another client appeared nearby until its moved..

_________________
**Выставляем отступы в скриптах*** ©Destruction

Feel the Power of Dark Side


Top
   
 Post subject:
PostPosted: 2007-12-18 21:03:02 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
ok i understand about player serch :) but another mistake with your skript :) if i dont have regents script goes spamed


Top
   
 Post subject:
PostPosted: 2007-12-18 21:07:47 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
ok tryed to slove by my self is it right ?
Code:
sub tt()
var timec
var myx = uo.getx('self')
var myy=uo.gety('self') #added
repeat
  uo.deletejournal()
  uo.waittargetobject('0x4000465D')
  uo.cast('Recall')
  timec=uo.timer()+80
  uo.deletejournal()
  while not uo.injournal('fizzles') and not uo.injournal('reagents') and not timec<uo.timer() and (myx==uo.getx('self') and myy==uo.gety('self'))
    wait(50)
  wend
until myx<>uo.getx('self') and myy<>uo.gety('self') or uo.injournal('reagents')
end sub



can you see this one ?
http://forum.yoko.com.ua/viewtopic.php?t=12925


Top
   
 Post subject:
PostPosted: 2007-12-19 02:45:10 
Offline
User avatar

Joined: 2007-11-01 19:09:30
Posts: 287
Location: Moscow
i'll look at the link.
And you, try to make smth. with "uo.injournal('reagents')" - play with that and it might stop repeating..

_________________
**Выставляем отступы в скриптах*** ©Destruction

Feel the Power of Dark Side


Top
   
 Post subject:
PostPosted: 2007-12-19 13:18:50 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
Maybe you can help me connect scripts? :) Link i gaved and this serch player :) ?


Top
   
 Post subject:
PostPosted: 2007-12-20 17:53:18 
Offline

Joined: 2007-11-13 00:39:14
Posts: 125
why this serching players cant find animals ?


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 12 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