SHARE
TWEET

Untitled

a guest Apr 19th, 2019 102 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. command /tempban [<offline player>] [<text>] [<timespan>]:
  2.     permission: mod
  3.     permission message: &6Insufficient Permissions.
  4.     trigger:
  5.         if argument 1 is not set:
  6.             send "&6&lPUNISHMENTS &8- &7Usage: &6/tempban <player> [<reason>] <timespan> [-s]"
  7.         else:
  8.             if argument 2 is not set:
  9.                 send "&6&lPUNISHMENTS &8- &7Usage: &6/tempban <player> [<reason>] <timespan> [-s]"
  10.             else:
  11.                 if argument 2 is "-s":
  12.                     loop all players:
  13.                         if loop-player has the permission "rank.helper":
  14.                             send "&7[Silent] &6&lPUNISHMENTS &8- &6%player% &7tempbanned &6%arg-1% &7for &6%arg-3% &7for &6N/A&7." to loop-player
  15.                     kick argument 1 because "&6&lPUNISHMENTS &8- &6%player% &7tempbanned &6You &7for &6%arg-3% &7for &6N/A&7."
  16.                     set {tempban.%arg-1%} to now
  17.                     set {tempbantime.%arg-1%} to argument 3
  18.                     stop
  19.                 else:
  20.                     if argument 2 contains "-s":
  21.                         set {_arg2} to argument 2
  22.                         replace all " -s" in {_arg2} with "&7."
  23.                         loop all players:
  24.                             if loop-player has the permission "rank.helper":
  25.                                 send "&7[Silent] &6&lPUNISHMENTS &8- &6%player% &7tempbanned &6%arg-1% &7for &6%arg-3% &7for &6%{_arg2}%"
  26.                         set {tempban.%arg-1%} to now
  27.                         set {tempbantime.%arg-1%} to argument 3
  28.                         kick argument 1 because "&6&lPUNISHMENTS &8- &6%player% &7tempbanned &6You &7for &6%arg-3% &7for &6%{_arg2}%"
  29.                     else:
  30.                         kick argument 1 because "&6&lPUNISHMENTS &8- &6%player% &7tempbanned &6You &7for &6%arg-3% &7for &6%arg-2%&7."
  31.                         set {tempban.%arg-1%} to now
  32.                         set {tempbantime.%arg-1%} to argument 3
  33.                         broadcast "&6&lPUNISHMENTS &8- &6%player% &7tempbanned &6%arg-1% &7for &6%{tempbantime.%arg-1%}% &7for &6%arg-2%&7."
  34.  
  35. on join:
  36.     if {tempban.%player%} is set:
  37.         set {_waited} to difference between {tempban.%player%} and now
  38.         if {_waited} is less than {tempbantime.%player%}:
  39.             set {_waited2} to difference between {tempbantime.%player%} and {_waited}
  40.             kick player because "&6&lPUNISHMENTS &8- &6You &7are tempbanned for &6%{_waited2}%&7."
  41.         else:
  42.             delete {tempban.%player%}
  43.             delete {tempbantime.%player%}
  44.  
  45. command /unban [<offline player>] [<text>]:
  46.     permission: mod
  47.     permission message: &6Insufficient Permissions.
  48.     trigger:
  49.         if argument 1 is not set:
  50.             send "&6&lPUNISHMENTS &8- &7Usage: &6/unban <player> [-s]"
  51.         else:
  52.             if argument 2 is not set:
  53.                 broadcast "&6&lPUNISHMENTS &8- &6%player% &7unbanned &6%arg-1%&7."
  54.             else:
  55.                 loop all players:
  56.                     if loop-player has the permission "rank.mod":
  57.                         send "&7[Silent] &6&lPUNISHMENTS &8- &6%player% &7unbanned &6%arg-1%&7." to loop-player
  58.             delete {ban.%arg-1%}
  59.             delete {banreason.%arg-1%}
  60.             delete {tempbantime.%arg-1%}
  61.             delete {tempban.%arg-1%}
  62.             unban argument 1
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top