Advertisement
Guest User

Punishing system with /history

a guest
Dec 14th, 2019
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.65 KB | None | 0 0
  1. Command /kick [<player>] [<text>]:
  2. permission: kick.sk
  3. permission message: &cYou do not have enough permissions to run this command!
  4. trigger:
  5. if arg-1 is set:
  6. if arg-2 is set:
  7. kick arg-1 due to "&cYou've been kicked due to &a%arg 2%&c!"
  8. broadcast "&3%player% &7Has kicked &3%arg-1%&7! &7[%arg 2%]"
  9. add 1 to {%uuid of arg-1%::kicks}
  10. else:
  11. send "&cWrong format! Do &7/kick <player> <reason>"
  12. else:
  13. send "&cWrong format! Do &7/kick <player> <reason>"
  14.  
  15. Command /warn [<player>] [<text>]:
  16. permission: kick.sk
  17. permission message: &cYou do not have enough permissions to run this command!
  18. trigger:
  19. if arg-1 is set:
  20. if arg-2 is set:
  21. broadcast "&3%player% &7Has warned &3%arg-1%&7! &7[%arg 2%]"
  22. add 1 to {%uuid of arg-1%::warns}
  23. else:
  24. send "&cWrong format! Do &7/warn <player> <reason>"
  25. else:
  26. send "&cWrong format! Do &7/warn <player> <reason>"
  27.  
  28. Command /mute [<offline player>] [<text>] [<timespan>]:
  29. permission: mute.sk
  30. trigger:
  31. if arg 1 is set:
  32. if arg 2 is set:
  33. if arg 3 is set:
  34. set {%uuid of arg-1%::muted::timespan} to (arg-3) later
  35. set {%uuid of arg-1%::muted} to true
  36. set {%uuid of arg-1%::muted::Reason} to arg-2
  37. broadcast "&3%player% &7Has muted &3%arg 1% &7for &c%arg 2%&7 [%arg-3%]"
  38. add 1 to {%uuid of arg-1%::mutes}
  39. else:
  40. send "&cDo: &7/mute <player> <reason> <time>"
  41. else:
  42. send "&cDo: &7/mute <player> <reason> <time>"
  43. else:
  44. send "&cDo: &7/mute <player> <reason> <time>"
  45.  
  46. Command /unban [<offline player>]:
  47. permission: tempban.sk
  48. trigger:
  49. set {%uuid of arg-1%::tempban} to false
  50. send "&3%player% &7Has unbanned &3%arg-1%&7" to all players
  51.  
  52.  
  53.  
  54.  
  55. on chat:
  56. if {%uuid of player%::muted} is not set:
  57. stop
  58. if {%uuid of player%::muted} is true:
  59. cancel event
  60. send "&7You currently cannot speak! [Reason: &c%{%uuid of player%::muted::reason}%&7]"
  61. else if {%uuid of player%::muted} is false:
  62. stop
  63.  
  64. every second:
  65. loop all players:
  66. if {%uuid of loop-player%::muted} is true:
  67. if now is greater than {%uuid of loop-player%::muted::timespan}:
  68. set {%uuid of loop-player%::muted} to false
  69. send "&7Your mute has run out!" to loop-player
  70. else:
  71. stop
  72. else:
  73. stop
  74.  
  75. Command /unmute [<offline player>]:
  76. permission: mute.sk
  77. trigger:
  78. if arg-1 is set:
  79. set {%uuid of arg-1%::muted} to false
  80. else:
  81. send "&cPlease specify a player!"
  82.  
  83. Command /tempban [<offline player>] [<text>] [<timespan>]:
  84. permission: tempban.sk
  85. trigger:
  86. if arg 1 is set:
  87. if arg 2 is set:
  88. if arg 3 is set:
  89. broadcast "&3%player% &7Has tempbanned &3%arg 1% &7for &c%arg 2%&7 [%arg 3%]"
  90. set {%uuid of arg-1%::tempban::timespan} to (arg-3) later
  91. set {%uuid of arg-1%::tempban} to true
  92. set {%uuid of arg-1%::tempban::reason} to arg-2
  93. add 1 to {%uuid of arg-1%::bans}
  94. kick arg-1 due to "%{%uuid of arg-1%::tempban::reason}%"
  95. else:
  96. send "&cDo: &7/tempban <player> <reason> <time>"
  97. else:
  98. send "&cDo: &7/tempban <player> <reason> <time>"
  99. else:
  100. send "&cDo: &7/tempban <player> <reason> <time>"
  101.  
  102. Command /ban [<offline player>] [<text>]:
  103. permission: tempban.sk
  104. trigger:
  105. if arg 1 is set:
  106. if arg 2 is set:
  107. broadcast "&3%player% &7Has tempbanned &3%arg 1% &7for &c%arg 2%&7 [&cPERMANENTLY]"
  108. set {%uuid of arg-1%::ban} to true
  109. set {%uuid of arg-1%::ban::reason} to arg-2
  110. add 1 to {%uuid of arg-1%::bans}
  111. kick arg-1 due to "%{%uuid of arg-1%::ban::reason}%"
  112. else:
  113. send "&cDo: &7/ban <player> <reason>"
  114. else:
  115. send "&cDo: &7/ban <player> <reason>"
  116.  
  117. on join:
  118. if {%uuid of player%::tempban} is not set:
  119. stop
  120. if {%uuid of player%::tempban} is true:
  121. kick player due to "&7Your currently banned! [Reason: &c%{%uuid of player%::tempban::reason}%&7]"
  122. else if {%uuid of player%::tempban} is false:
  123. stop
  124. if {%uuid of player%::ban} is true:
  125. kick player due to "&7Your permanently banned! [Reason: &c%{%uuid of player%::ban::reason}%&7]"
  126. else if {%uuid of player%::ban} is false:
  127. stop
  128. if {%uuid of player%::playtime::m} is not set:
  129. set {%uuid of player%::playtime::m} to 0
  130. if {%uuid of player%::playtime::s} is not set:
  131. set {%uuid of player%::playtime::s} to 0
  132. if {%uuid of player%::playtime::h} is not set:
  133. set {%uuid of player%::playtime::h} to 0
  134.  
  135. every second:
  136. loop all players:
  137. if {%uuid of loop-player%::tempban} is true:
  138. if now is greater than {%uuid of loop-player%::tempban::timespan}:
  139. set {%uuid of loop-player%::tempban} to false
  140. else:
  141. stop
  142. else:
  143. stop
  144.  
  145. Command /history [<player>]:
  146. permission: helper.sk
  147. trigger:
  148. send ""
  149. send "&6&l%arg-1%'s Punishment History"
  150. send ""
  151. send "&7Warns: &a%{%uuid of player%::warns}%"
  152. send "&7Kicks: &a%{%uuid of player%::kicks}%"
  153. send "&7Mutes: &a%{%uuid of player%::mutes}%"
  154. send "&7Bans: &a%{%uuid of player%::bans}%"
  155. send ""
  156. send "&7Status: %{%player%.status}%"
  157. send "&7Total punishments: &a%{%uuid of player%::bans} + {%uuid of player%::mutes} + {%uuid of player%::kicks} + {%uuid of player%::warns}%"
  158. send ""
  159.  
  160. every 5 seconds:
  161. loop all players:
  162. while loop-player is online:
  163. set {%loop-player%.status} to "&aOnline"
  164. while loop-player is offline:
  165. set {%loop-player%.status} to "&cOffline"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement