Yoko

All sides of Injection
It is currently 2025-10-14 20:43:20

All times are UTC+02:00




Post new topic  Reply to topic  [ 6 posts ] 
Author Message
PostPosted: 2011-03-03 16:21:19 
Offline

Joined: 2011-03-03 16:12:17
Posts: 4
Доброго вечера всем!
Хочу сделать авто скрипты.
Раньше запускал каждый в отдельности, теперь хочу один и чтобы он включал все другие.

Основной

sub all()
WHILE not uo.Dead()
r()
t()
w()
q()
e()
WEND
end sub




sub r()
if uo.injournal("You are frozen") then
uo.attack ('laststatus')
uo.attack ('laststatus')
UO.Exec("waittargetself")
wait(100)
UO.Cast("Magic Arrow")
wait(1500)
uo.deletejournal()
endif
end sub







sub w()
if UO.mana<40 then
uo.deletejournal()
uo.msg(" .drink_mana_total")
wait(100)
end if
end sub

sub t()
if UO.life<150 then
uo.deletejournal()
UO.usetype("0x0F91")
wait(100)
UO.usetype("0x3F14")
UO.Exec("waittargetself")
wait(2000)
end if
end sub



(Тут можно если стамина меньше допустим 70ти на 10)
sub q()
uo.deletejournal()
if uo.injournal("You are too fatigued") then
uo.msg(" .drink_refresh_total")
uo.deletejournal()
endif
end sub

И самый сложный

sub e()
while NOT uo.injournal("feel normal")
uo.deletejournal()
if uo.injournal("You weak")
UO.Exec("cast 'Cure'self")
wait(1500)
uo.deletejournal()
endif
wend
end sub



Вроде работает, но с перебоями, с хилом всегда проблема. Иногда ману допустим пьет а из парала уже не воводит стрелку не кастует, да и такое чувствтво что висеть начинает зверски. Помоги плиз поправить. Спасибо заранее!


Top
   
PostPosted: 2011-03-03 17:25:14 
Offline
User avatar

Joined: 2009-05-28 09:58:28
Posts: 2802
Location: Иваново
Вот так вот как то более по божески выглядит:

Code:
sub all()
   uo.deletejournal()
   WHILE not uo.Dead()
      a()
      b()
      c()
      d()
      e()
   WEND
end sub
sub a()
   if uo.injournal("You are frozen") then
      uo.attack ('laststatus')
      uo.attack ('laststatus')
      uo.waittargetself()
      wait(100)
      UO.Cast("Magic Arrow")
      wait(1500)
      uo.deletejournal()
   endif
end sub
sub b()
   if UO.life<150 then
      UO.usetype("0x0F91")
      wait(100)
      uo.waittargetself()
      UO.usetype("0x3F14")
      wait(2000)
   end if
end sub
sub c()
   if UO.mana<40 then
      uo.msg(".drink_mana_total")
      wait(100)
   end if
end sub
sub d()
   if uo.injournal("You are too fatigued") then
      uo.msg(".drink_refresh_total")
      uo.deletejournal()
   endif
end sub
sub e()
   while NOT uo.injournal("feel normal")    ; вот изза этого условия и зависает
      uo.deletejournal()
      if uo.injournal("You weak")
         uo.Cast('Cure', 'self')
         uo.deletejournal()
         wait(1500)
      endif
   wend                     ; вот изза этого условия и зависает
end sub


я просто не очень понимаю зачем такую пирамиду строить... Ну я в пвп не очень разбираюсь.

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


Top
   
PostPosted: 2011-03-03 21:46:24 
Offline

Joined: 2011-03-03 16:12:17
Posts: 4
Спасибо!
Но...
Точно не хватало в этой строке if uo.injournal("You weak") оператора then

И как токо начал тестить сразу
Unhandled expresion in phrase (Читал лечится прогой настраиваемой для одного проца на несколькоядерном, да не особо помогло...)
И ошибка:
Acsess violation at adress 21017D... Впервые вижу такую...

И если честно, работать стал еще хуже, подвисать моментально при любом касте. При появлении Ю вик в журнале курит через раз, и то один раз, а не до тех пор пока не напишется, что нормал. Да и пить ману и хил, все тоже фактически не работает в переделанном скрипте((

Подскажи плиз, ведь уверен, можно сделать все эти 5 скриптов вместе чтобы на репите нормально работали... Спасибо заранее!


Top
   
PostPosted: 2011-03-04 11:21:59 
Offline

Joined: 2011-03-03 16:12:17
Posts: 4
И скорее всего дело все таки в этих скриптах

sub d()
if uo.injournal("You are too fatigued") then
uo.msg(".drink_refresh_total")
uo.deletejournal()
endif
end sub
sub e()
while NOT uo.injournal("feel normal") ; вот изза этого условия и зависает
uo.deletejournal()
if uo.injournal("You weak")
uo.Cast('Cure', 'self')
uo.deletejournal()
wait(1500)
endif
wend ; вот изза этого условия и зависает
end sub

В одном из них двух.
Т.к. когда удаляю их из списка основного скрипта. но они все равно висят написанные в инже- подлагивает, как токо удалил их вообще. Стали три остальных и работать норм и вроде подвисать не особо.

И все таки очень прошу помощи, особенно на скрипт с отхилом.


Top
   
PostPosted: 2011-03-04 15:34:42 
Offline
User avatar

Joined: 2009-05-28 09:58:28
Posts: 2802
Location: Иваново
С утра написал, забыл нажать кнопку отправить :mrgreen:

было бы проще если бы ты подробно описал что именно в твоем представлении должен делать скрипт. Так скать алгоритм.

Code:
sub all()
   uo.deletejournal()
   WHILE not uo.Dead()
      a()
      b()
      c()
      d()
      e()
      wait(500)
   WEND
end sub
sub a()
   if uo.injournal("You are frozen") then
      UO.Cast("Magic Arrow", 'self')
      wait(1500)
      uo.deletejournal()
   endif
end sub
sub b()
   if UO.life<150 then
      UO.usetype("0x0F91")
      wait(100)
      uo.waittargetself()
      UO.usetype("0x3F14") ;  это что за предмет?
      wait(2000)
   end if
end sub
sub c()
   if UO.mana<40 then
      uo.msg(".drink_mana_total")
      wait(100)
   end if
end sub
sub d()
   if uo.injournal("You are too fatigued") then
      uo.msg(".drink_refresh_total")
      uo.deletejournal()
      wait(500)
   endif
end sub
sub e()
   if uo.injournal("You weak") then
      uo.Cast('Cure', 'self')
      uo.deletejournal()
      wait(1500)
   endif
end sub
вот такую редакцию попробуй.

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


Top
   
PostPosted: 2011-03-04 16:08:30 
Offline

Joined: 2011-03-03 16:12:17
Posts: 4
Спасибо! Так вроде бы гораздо лучше на первый взгляд, чутка подвисает, ну это может быть просто перегрузил скриптами. А все таки чтоб он переставал кастовать кур увидев фразу You normal нельзя никак настроить? Спасибо еще раз!


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 6 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:  
Powered by phpBB® Forum Software © phpBB Limited