Advertisement
Guest User

Изъятие найденного

a guest
May 29th, 2017
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. !5::
  2. tftime := ""
  3. tfplayer := ""
  4. tfitem := ""
  5. loop, read, %A_MyDocuments%\GTA San Andreas User Files\SAMP\chatlog.txt
  6. {
  7.     if RegExMatch(A_LoopReadLine, "^\[(.*?)\] \|__________ Найденные вещи у (.*?) __________\|", s)
  8.     {
  9.         tftime := s1
  10.         tfplayer := s2
  11.     }
  12. }
  13. loop, read, %A_MyDocuments%\GTA San Andreas User Files\SAMP\chatlog.txt
  14. {
  15.     if RegExMatch(A_LoopReadLine, "^\[" tftime "\] \* Найдены \d+ гр\. .*? порошка\.")
  16.     {
  17.         sendinput {f6}/take drugs %tfplayer%{enter}
  18.         sleep 1150
  19.         continue
  20.     }
  21.     if RegExMatch(A_LoopReadLine, "^\[" tftime "\] \* Обнаружены материалы: \d+\.")
  22.     {
  23.         sendinput {f6}/take materials %tfplayer%{enter}
  24.         sleep 1150
  25.         continue
  26.     }
  27.     if RegExMatch(A_LoopReadLine, "^\[" tftime "\] \* Обнаружен HackRadar\: \d+ глушилок.")
  28.     {
  29.         sendinput {f6}/take hackradar %tfplayer%{enter}
  30.         sleep 1150
  31.         continue
  32.     }
  33.     if RegExMatch(A_LoopReadLine, "^\[" tftime "\] \* Обнаружены бланки\: \d+\.")
  34.     {
  35.         sendinput {f6}/take blanks %tfplayer%{enter}
  36.         sleep 1150
  37.         continue
  38.     }
  39. }
  40. return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement