controls.sk

Created by NicholasTheCoder

Just so you know, we don't know the file format for every file. If it's just a bunch of random characters, it's probably a .zip or .jar.

#Server Controls 1.9
#Made by NicholasTheCoder

on join:
	if {banned::%player%} is true:
			kick player due to "&c&lYou are Banned from the server!%nl%%nl%%nl%&eReason: &c%{banned::%player%::reason}%"
			stop

on chat:
	if {muted::%player%} is true:
		cancel event
		send "&dBe Quiet! You are muted for &ePermanent!"
		stop

on load:
	broadcast "&a&lServer Controls has been loaded!"
	wait 2 seconds
	broadcast "&6Changelog:"
	broadcast "&6*Bug Fixes on Punishment System
	wait 1 second
	broadcast "&6End of changelog!"

command /servercontrols [<player>] [<text>]:
	permission: servercontrols.gui
	permission message: &9You do not have permission!
	trigger:
		if argument 1 is set:
			if argument 2 is not set:
				if argument 3 is not set:
					open chest with 2 rows named "       Server Controls 1.9" to player
					format slot 0 of player with pink stained glass named " " to be unstealable
					format slot 1 of player with pink stained glass named " " to be unstealable
					format slot 2 of player with emerald block named "&a&lReload" with lore "&aReloads the server" to close then run [execute console command "/reload"]
					format slot 3 of player with pink stained glass named " " to be unstealable
					format slot 4 of player with cookie named "&6&lRestart" with lore "&6Restarts the server" to close then run [execute console command "/restart"]
					format slot 5 of player with pink stained glass named " " to be unstealable
					format slot 6 of player with barrier named "&c&lStop" with lore "&cStops the server" to close then run [execute console command "/stop"]
					format slot 7 of player with pink stained glass named " " to be unstealable
					format slot 8 of player with pink stained glass named " " to be unstealable
				else:
					open chest with 1 row named "		    PUNISH"
					format slot 0 of player with barrier named "&c&lNOTICE" with lore "&cAll punishments are final and cannot ||&r&cun-done." to be unstealable
					format slot 2 of player with gold block named "&6&lBAN" to close then run [execute console command "/guiban %arg-1% %arg-2%"]
					format slot 4 of player with emerald block named "&a&lMUTE" to close then run [execute console command "/guimute %arg-1% %arg-2%"]
					format slot 6 of player with paper named "&aWarning" to close then run [send "&aWarning &cYou have been warned for &e%arg-2%! to arg-1]
					format slot 8 of player with barrier named "&c&lNOTICE" with lore "&cAll punishments are final and cannot ||&r&cun-done." to be unstealable


command /guiban [<text>] [<text>]:
	executable by: console
	trigger:
		set {_player} to arg 1 parsed as offlineplayer

		set {banned::%{_player}%} to true
		set {banned::%{_player}%::reason} to arg 2
		
		kick {_player} due to "&c&lYou are Banned from the server!%nl%%nl%%nl%&eReason: &c%{banned::%player%::reason}%"

command /guimute [<text>] [<text>]:
	executable by: console
	trigger:
		set {_player} to arg 1 parsed as offlineplayer

		set {muted::%{_player}%} to true
		set {muted::%{_player}%::reason} to arg 2

		send "&a&lMUTE &aYou have been muted for &c%{muted::%{_player}%::reason}%!" to arg-1

command /info:
	aliases: /scinfo, /servercontrolsinfo
	trigger:
		send ""
		send "&a&lServerControls 1.9"
		send "&aCreated by NicholasTheCoder."
		send ""
		send "&cNOT TO BE REPRODUCED WITHOUT MY PERMISSION!"