Yoko

All sides of Injection
It is currently 2026-01-18 16:16:40

All times are UTC+02:00




Post new topic  Reply to topic  [ 4 posts ] 
Author Message
PostPosted: 2005-04-05 18:38:06 
Offline

Joined: 2004-07-14 22:56:46
Posts: 82
Location: Украина, Одесса
Вроде написал довольно полезный скрипт-примочку для основного макроса. Смысл такой: если в журнале отлетит фраза "Stop!" то основная макра тормозится, а дополнение выводило окошко текста и писало изменение в скилле, время прокачки, кол-во ресурсов израсходованных\выкопанных.


Last edited by Denton on 2005-04-06 15:13:20, edited 1 time in total.

Top
   
 Post subject:
PostPosted: 2005-04-05 20:50:05 
Offline
User avatar

Joined: 2004-06-18 09:03:31
Posts: 83
а ты долго думал ? чтоб такое написать...


Top
   
 Post subject:
PostPosted: 2005-04-05 21:35:46 
Offline

Joined: 2004-07-14 22:56:46
Posts: 82
Location: Украина, Одесса
Я его не обдумывал еще.


Top
   
 Post subject:
PostPosted: 2005-04-06 15:10:49 
Offline

Joined: 2004-07-14 22:56:46
Posts: 82
Location: Украина, Одесса
Моя версия скрипта:
Code:
sub sledilka(mainskill)
var time, success, fizzle, resources, skill
skill=uo.skillval(mainskill)
resources=uo.count(material)
time=0
success=0
fizzle=0
while not uo.injournal("Stop!")
   repeat
      time=time+1
      wait(1000)
   until uo.injournal("put") or uo.injournal("fail") or uo.injournal("Stop!")
   if uo.injournal("put") then
      success=success+1
      uo.deletejournal()
   endif
   if uo.injournal("fail") then
      fizzle=fizzle+1
      uo.deletejournal()
   endif
wend
resources=resources-uo.count(material)
skill=(uo.skillval(mainskill)-skill)/10
uo.textopen()
uo.textprint("Скилл вырос на "+str(skill))
uo.textprint("за "+str(time)+" секунд")
uo.textprint("При этом было использовано "+str(resources)+" материала")
uo.textprint("Статистика успехов\физлов")
uo.textprint("Успешных "+str(success)+" попыток")
uo.textprint("Безуспешных "+str(fizzel)+" попыток")
uo.deletejournal()
uo.Print('Все функции скрипта выключены!')
uo.DeleteJournal()
uo.Exec('terminate all')
wait(100)
uo.Exec('terminate all')
wait(100)
uo.Exec('terminate all')
wait(100)
end sub

В начало текста основного макроса добавить такие строки:
Code:
var skill
skill="скил за которым следим"

После этого, вот такое:
Code:
uo.exec('addtype material') 
while uo.targeting()
wait(100)
wend


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 2 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