boryso15

Skrypt dla Serwera uPvP

Jun 22nd, 2015
255
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.87 KB | None | 0 0
  1. #[PvPrangs][v1.0]
  2. # by boryso15
  3. # for uPvP
  4. #======================================================================#
  5. # Skrypt stworzony przez boryso15 | Specjalnie dla UPvP #
  6. #======================================================================#
  7.  
  8. #===================================#
  9. # LICENCJA #
  10. #===================================#
  11. # ZAKAZ: #
  12. # * Modyfikowania treści skryptu #
  13. # * Przywłaszczania sobie #
  14. # autorstwa skryptu #
  15. # * Zarabiania na skrypcie #
  16. # * Udostępniania skryptu w swoich #
  17. # paczkach serwerowych #
  18. # * Usuwania treści zawierających #
  19. # informacje o autorze #
  20. # * Podszywania się pod autora #
  21. #===================================#
  22. # POZWOLENIA: #
  23. # * Modyfikowanie wiadomości #
  24. # skryptu na własne potrzeby #
  25. #===================================#
  26. # Mylnie odczytana licencja nie #
  27. # zwalnia z przestrzegania jej! #
  28. #===================================#
  29.  
  30. on load:
  31. send "&f[&5PvP&arangs&f][v.1.0]&6 LADOWANIE " to console
  32. send "&f[&5PvP&arangs&f]&5PvP&arangs&f by &5&lboryso15 for &2u&7PvP" to console
  33. if folder "plugins/PvPrangs" doesn't exists:
  34. send "&f[&5PvP&arangs&f]&c BRAK POTRZEBNYCH PLIKOW" to console
  35. send "&f[&5PvP&arangs&f]&2 TWORZENIE POTRZEBNYCH PLKOW" to console
  36. create folder "plugins/PvPrangs/PLAYERS"
  37. on unload:
  38. send "&f[&5PvP&arangs&f]&6 WYLACZANIE" to console
  39. every 720 minutes:
  40. clear {_loopplayer::*}
  41. set {_loopplayer::*} to all files in "plugins/PvPrangs/PLAYERS/"
  42. loop {_loopplayer::*}:
  43. set {_nickname} to single value "nickname" get of "plugins/PvPrangs/PLAYERS/%loop-value%"
  44. set {_dateofexpired} to single value "dateofexpired" get of "plugins/PvPrangs/PLAYERS/%loop-value%"
  45. set {_datefromnow} to subtext of "%now%" between 0 and 5
  46. if {_datefromnow} is {_dateofexpired}:
  47. execute console command "/pex user %{_nickname}% group set default"
  48. send "&f[&5PvP&arangs&f] %{_nickname}% zostal zdegradowany do rangi default" to console
  49. send "&f[&5PvP&arangs&f] %{_nickname}% zostal/a zdegradowany/a do rangi domyslnej" to all players
  50. df "plugins/PvPrangs/PLAYERS/%{_nickname}%.yml"
  51.  
  52. command /miesiac <text> <text>:
  53. usage: &5&l/miesiac <gracz> <ranga>
  54. trigger:
  55. if executor have permissions "advranks.promote" or "*" or "advranks.*":
  56. set {_ndate} to subtext of "%now%" between 0 and 5
  57. set "nickname" to "%argument 1%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  58. set "rank" to "%argument 2%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  59. set {_nday} to subtext of "%now%" between 0 and 2
  60. set {_nmonth} to subtext of "%now%" between 4 and 5
  61. if {_nmonth} is "1":
  62. set {_emonth} to "2"
  63. if {_nmonth} is "2":
  64. set {_emonth} to "3"
  65. if {_nmonth} is "3":
  66. set {_emonth} to "4"
  67. if {_nmonth} is "4":
  68. set {_emonth} to "5"
  69. if {_nmonth} is "5":
  70. set {_emonth} to "6"
  71. if {_nmonth} is "6":
  72. set {_emonth} to "7"
  73. if {_nmonth} is "7":
  74. set {_emonth} to "8"
  75. if {_nmonth} is "8":
  76. set {_emonth} to "9"
  77. if {_nmonth} is "9":
  78. set {_emonth} to "10"
  79. if {_nmonth} is "10":
  80. set {_emonth} to "11"
  81. if {_nmonth} is "11":
  82. set {_emonth} to "12"
  83. if {_nmonth} is "12":
  84. set {_emonth} to "1"
  85. set {_edate} to "%{_nday}%.%{_emonth}%"
  86. set "date" to "%{_nday}%.%{_nmonth}%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  87. set "dateofexpired" to "%{_edate}%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  88. send "%player%: mianowal %argument 1% na %argument 2% na 1 miesiac" to console
  89. send "&f[&5PvP&arangs&f] %argument 1% zostal/a mianowany/a na %argument 2% na 1 miesiąc" to all players
  90. execute console command "/pex user %argument 1% group set %argument 2%"
  91. exit
  92. else:
  93. send "&f[&5PvP&arangs&f]&c Nie masz uprawnien" to player
  94. exit
  95. command /czas <text> <text> <text>:
  96. usage: &5&l/czas <gracz> <ranga> <dzień.miesiąc>
  97. trigger:
  98. if executor have permissions "PvPrangs.promote" or "*" or "PvPrangs.*":
  99. set "nickname" to "%argument 1%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  100. set "rank" to "%argument 2%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  101. set {_nday} to subtext of "%now%" between 0 and 2
  102. set {_nmonth} to subtext of "%now%" between 4 and 5
  103. set "date" to "%{_nday}%.%{_nmonth}%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  104. set "dateofexpired" to "%argument 3%" in yaml file "plugins/PvPrangs/PLAYERS/%argument 1%.yml"
  105. send "%player%: mianowal %argument 1% na %argument 2% do %argument 3%" to console
  106. send "&f[&5Advanced&aRanks&f] %argument 1% zostal/a mianowany/a na %argument 2% do %argument 3%" to all players
  107. execute console command "/pex user %argument 1% group set %argument 2%"
  108. exit
  109. else:
  110. send "&f[&5PvP&arangs]
  111. command /rangi <text>:
  112. usage: &5&l/rangi <reload/pomoc/info>
  113. trigger:
  114. if argument 1 is "pomoc":
  115. send "&a========================================================================================" to executor
  116. send " &f[&5PvP&arangs&f]" to executor
  117. send "&a========================================================================================" to executor
  118. send "&5/miesiac <gracz> <ranga> - ustawia rangę gracza na 1 miesiąc" to executor
  119. send "&5/czas <gracz> <ranga> <dzień.miesiąc> - ustawia rangę do daty określonej w komendzie" to executor
  120. send "&5/PvP reload - przeładowuje "PvP rangs" to executor
  121. send "&a========================================================================================" to executor
  122. exit
  123. if argument 1 is "reload":
  124. if executor have permissions "PvPrangs .reload" or "*" or "PvPrangs.*":
  125. execute console command "/sk reload %script%"
  126. exit
  127. else:
  128. send "&f[&5PvP&arangs&f]&c Nie masz uprawnien" to player
  129. exit
  130. if argument 1 is "info":
  131. send "&f[&5PvP&arangs&f] stworzony przez boryso15 dla &f[&2U&fPvP]" to executor
  132. exit
Advertisement
Add Comment
Please, Sign In to add comment