szumielxd

Search

Dec 8th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.29 KB | None | 0 0
  1. command /searchsk <text>:
  2. permission: wlasciciel
  3. trigger:
  4. if arg is "-stop":
  5. if {searchsk.stop.%player%} is not set:
  6. send "&cNie wykonujesz zadnej czynnosci"
  7. stop
  8. else:
  9. set {searchsk.stop.%player%} to true
  10. stop
  11. set {_s::*} to files in dir "plugins/Skript/scripts"
  12. if {searchsk.stop.%player%} is false:
  13. send "Juz wykonujesz ten proces"
  14. stop
  15. set {searchsk.stop.%player%} to false
  16. send "&a&lZnaleziono &7&l%size of {_s::*}% &a&lplikow"
  17. loop {_s::*}:
  18. if {searchsk.stop.%player%} is true:
  19. send "&a&lZatrzymuje szukanie"
  20. delete {searchsk.stop.%player%}
  21. stop
  22. file "%loop-value%" is not a directory:
  23. set {_low} to 1
  24. wait 10 ticks
  25. set {_m} to loop-value
  26. replace all "/home/servers/mcsurvi/
  27. send "&2Przeszukuje plik '&a%{_m}%&2':"
  28. set {_i} to 0
  29. while line count of file loop-value is not smaller than {_low}:
  30. file loop-value's line {_low} contains arg:
  31. send " &aZnaleziono fraze &e'%arg%' &aw &e%{_low}% &alinijce"
  32. add 1 to {_low}
  33. add 1 to {_i}
  34. if {searchsk.stop.%player%} is true:
  35. send "&a&lZatrzymuje szukanie"
  36. delete {searchsk.stop.%player%}
  37. stop
  38. if {_i} is 5:
  39. set {_i} to 0
  40. wait 1 ticks
  41. delete {searchsk.stop.%player%}
  42. send "&a&lKoniec"
Add Comment
Please, Sign In to add comment