Yoko

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

All times are UTC+02:00




Post new topic  Reply to topic  [ 5 posts ] 
Author Message
PostPosted: 2005-04-22 00:14:34 
Offline
Junior Expert
User avatar

Joined: 2004-11-13 00:43:55
Posts: 474
Location: Киберзадроцк
Я знаю им некто не будет пользоватся, но просто от нефиг делать написал такую фигню :)
Code:
sub CountMan()
var f, FileName=("c:\Status.html")
var n_1, n_2=0, Namber=0, ID_TMP, CheckTime, SexName
Dim ID[200], Name[200], Sex[200], Color[200], LastTime[200]

Dim ManType[3]
    ManType[0] = 2
    ManType[1] = '0x0190' ; Поиск Людей (М).
    ManType[2] = '0x0191' ; Поиск Людей (Ж).

UO.Set('finddistance','12')
UO.IgnoreReset()
UO.Ignore('self')
REPEAT
   For n_1 = 1 TO ManType[0]
      REPEAT
         UO.FindType(ManType[n_1],'-1','1')
            If UO.FindCount() Then
               ID_TMP = UO.GetSerial('finditem')
                  If ID_TMP<>'0xFFFFFFFF' Then
                     UO.Click(ID_TMP)
                     UO.DeleteJournal()
                     CheckTime = UO.Timer()+50
                        REPEAT
                           Wait(500)
                        Until UO.JournalSerial('0')==ID_TMP or CheckTime < UO.Timer() or UO.Dead()
                        If UO.GetName(ID_TMP)<>'' Then
                           Namber           = Namber+1
                           ID[Namber]       = ID_TMP
                           Name[Namber]     = UO.GetName(ID_TMP)
                           Sex[Namber]      = n_1
                           Color[Namber]    = UO.GetNotoriety(ID_TMP)
                           LastTime[Namber] = PrintTime()
                           UO.Ignore(ID_TMP)
                        End If
                  End If
            EndIf
      Until UO.FindCount()==0 or UO.Dead()
   Next
   If Namber > n_2 Then
      f = file(FileName)
      f.create()
      f.open()
      f.writeln('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">')
      f.writeln('<HTML>')
      f.writeln('<HEAD>')
      f.writeln('<TITLE> Статистика Окружаюших </TITLE>')
      f.writeln('<META HTTP-EQUIV="Content-Language" CONTENT="ru"/>')
      f.writeln('<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=windows-1251"/>')
      f.writeln('</HEAD>')
      f.writeln('<BODY topmargin="10" leftmargin="0" bgcolor="#E5E5E5">')
      f.writeln('<TABLE align="center" border="1" cellpadding="0" cellspacing="0" width="80%">')
         For n_1 = 1 TO Namber
            f.writeln('<TR>')
            f.writeln('<TD align="center">')
            f.writeln(str(n_1))
            f.writeln('</TD>')
            f.writeln('<TD>')
            f.writeln("<B>ID Чара: </B><I>'"+ID[n_1]+"'</I>")
            f.writeln('</TD>')
            f.writeln('<TD>')
               If Color[n_1]==0 Then
                  f.writeln("<B>Имя Чара:</B> <SPAN style='font-size: 17;'>"+Name[n_1]+"</SPAN>")
               Else
                  If Color[n_1]==1 Then
                     f.writeln("<B>Имя Чара:</B> <SPAN style='font-size: 17; color: blue;'>"+Name[n_1]+"</SPAN>")
                  Else
                     If Color[n_1]==2 Then
                        f.writeln("<B>Имя Чара:</B> <SPAN style='font-size: 17; color: green;'>"+Name[n_1]+"</SPAN>")
                     Else
                        If Color[n_1]==3 Then
                           f.writeln("<B>Имя Чара:</B> <SPAN style='font-size: 17; color: #666666;'>"+Name[n_1]+"</SPAN>")
                        Else
                           If Color[n_1]==5 Then
                              f.writeln("<B>Имя Чара:</B> <SPAN style='font-size: 17; color: #FF3300;'>"+Name[n_1]+"</SPAN>")
                           Else
                              If Color[n_1]==6 Then
                                 f.writeln("<B>Имя Чара:</B> <SPAN style='font-size: 17; color: red;'>"+Name[n_1]+"</SPAN>")
                              End If
                           End If
                        End If
                     End If
                  End If
               End If
            f.writeln('</TD>')
            f.writeln('<TD>')
               If Sex[n_1]==1 Then
                  f.writeln("<B>Пол: </B>M")
               Else
                  f.writeln("<B>Пол: </B>Ж")
               End If            
            f.writeln('</TD>')
            f.writeln('<TD>')
            f.writeln("<B>Время:</B> "+LastTime[n_1])
            f.writeln('</TD>')
            f.writeln('</TR>')
         Next
         If Color[1]==0 Then
            f.writeln('<TR>')
            f.writeln("<TD align='center' colspan=5>")
            f.writeln("<SPAN style='font-size: 15'>У вас выключена опция <U>TWI</U> (Treck World Item) из-за этого не показывается цветные ники</SPAN> <SPAN style='font-size: 13'>(<SPAN style='color: red;'>ПК</SPAN>, <SPAN  style='color: #666666;'>Криминал</SPAN>, <SPAN  style='color: blue;'>Cиний</SPAN>, <SPAN  style='color: #FF3300;'>Враг</SPAN>\<SPAN  style='color: green;'>Союзник</SPAN>)</SPAN>")
            f.writeln('</TD>')
            f.writeln('</TR>')
         End If
      f.writeln('</TABLE>')
      f.writeln('</BODY>')
      f.writeln('</HTML>')
      f.close()
      n_2 = Namber
      UO.Print("Human's: ["+str(Namber)+"]")
   End If
Wait(500)
Until UO.Dead()
end sub

Sub PrintTime()
var HR  = ''
var MIN = ''
var SEC = ''
var CurrentTime = UO.Time() 
If CurrentTime > 99999 Then
   HR  = Mid(STR(CurrentTime),0,2)
   MIN = Mid(STR(CurrentTime),2,2)
   SEC = Mid(STR(CurrentTime),4,2)
Else
   If CurrentTime > 9999 Then
      HR  = '0'+Mid(STR(CurrentTime),0,1)
      MIN = Mid(STR(CurrentTime),1,2)
      SEC = Mid(STR(CurrentTime),3,2)
   Else
      If CurrentTime > 999 Then
         HR  = '00'
         MIN = Mid(STR(CurrentTime),0,2)
         SEC = Mid(STR(CurrentTime),2,2)
      Else
         If CurrentTime > 99 Then
            HR  = '00'
            MIN = '0'+Mid(STR(CurrentTime),0,1)
            SEC = Mid(STR(CurrentTime),1,2)
         Else
            If CurrentTime > 9  Then
               HR  = '00'
               MIN = '00' 
               SEC = STR(CurrentTime)
            Else
            HR  = '00'
            MIN = '00' 
            SEC = '0'+STR(CurrentTime)         
            End If
         End If
      End If
   End If
End If
Return (HR+':'+MIN+':'+SEC)   
end sub


Last edited by 666Man666 on 2005-04-23 17:18:06, edited 8 times in total.

Top
   
 Post subject:
PostPosted: 2005-04-22 00:36:57 
Offline
Expert!
User avatar

Joined: 2004-10-15 22:38:04
Posts: 1396
Location: Moscow City.
Прикольео :lol:
Другой вопрос а оно надо? =)
Хотя способов применений много =)


Top
   
 Post subject:
PostPosted: 2005-04-22 07:18:20 
Offline
User avatar

Joined: 2004-07-22 16:07:11
Posts: 260
Прошу написать значения этого скрипта, не все заходящие на этот топик понимают, для чего он служит.


Top
   
 Post subject:
PostPosted: 2005-04-22 08:41:40 
Offline
Junior Expert
User avatar

Joined: 2004-11-13 00:43:55
Posts: 474
Location: Киберзадроцк
Скрипт ишет вокруг чара других чаров М\Ж (НПЦ тоже записует :) ) если находит то пишет статистику в фаил c:\Status.html...
вот собсна всё что он делает.... я же и говорю им наврядли кто-то реально будет пользоватся, но просто так поигратся можно :)


Top
   
 Post subject:
PostPosted: 2005-04-23 12:44:22 
Offline
Expert!
User avatar

Joined: 2004-10-15 22:38:04
Posts: 1396
Location: Moscow City.
[Флуд не по теме мертв.]


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