server-tools 0.2.sk

Created by Michele

Other available versions. Ordered by newest to oldest versions:

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.

#UPDATER | DON'T TOUCH |
on skript start:
    set {_devbuild} to line 3 from url "https://pastebin.com/raw/rMtrHYLL"
    if {_devbuild} is 0.1:
        send "&1[ServerTools] &aUsing the lastest version!" to the console
        stop
    else:
        send "&1[ServerTools] &4Update found! Download at: https://github.com/buccimichele5/ServerTools-MC-Skript" to console

#CONFIG-READER | DON'T TOUCH |

on skript start:
    set {_configvers} to line 5 from url "https://pastebin.com/raw/rMtrHYLL"

Command /update-st:
    trigger:
        if {_devbuild} is 0.2:
            send "&1[ServerTools] &aUsing the lastest version!" to player
        else:
            send "&1[ServerTools] &4Update found! Download at: https://github.com/buccimichele5/ServerTools-MC-Skript" to player

Command /help-st:
    trigger:
        send "/help-st : Shows this list"
        send "/update-st : check for updates"
        send "/servertools : Shows info about servertools"
        send "/gmc : Sets the gamemode to creative"
        send "/gms : Sets gamemode to survival"
        send "/gma : Sets gamemode to adventure"
        send "/gmsp : Sets gamemode to spectator"
        send "/panel : Shows the panel link"
        send "/report : Report a player"
        send "/check : Checks if a player got reported"
        send "/setmotd : Sets a join message"
        send "/showmotd : Shows the join message"
        send "/setjome : Set your home to current location"
        send "/home : Teleport at your home"

Command /servertools:
    trigger: 
        send "&4==================ServerTools================="
        send "&aThis server is running ServerTools"
        send "&eVersion: 0.2"
        send "&1Build: 3-(Released)"
        send "&3Made by: buccimichele5"
        send "&4=============================================="

Command /gmc <player>:
    trigger:
        player has permission "gm.sut":
            make console execute command "gamemode creative %arg-1%"
            send "Set gamemode to creative"
        else:
            send "%{_noperms}%"

Command /gms <player>:
    trigger:
        player has permission "gm.sut":
            make console execute command "gamemode survival %arg-1%"
            send "Set gamemode to survival"
        else:
            send "%{_noperms}%"

Command /gma <player>:
    trigger:
        player has permission "gm.sut":
            make console execute command "gamemode adventure %arg-1%"
            send "Set gamemode to adventure"
        else:
            send "%{_noperms}%"

Command /gmsp <player>:
    trigger:
        player has permission "gm.sut":
            make console execute command "gamemode spectator %arg-1%"
            send "Set gamemode to spectator"
        else:
            send "%{_noperms}%"

Command /panel:
    trigger:
        player has permission "ppanel.sut":
            send "Panel currently disabled"
        else:
            send "%{_noperms}%"

Command /sudo <player> <text>:
    trigger:
        player has permission "sudo.sut":
            make arg-1 execute command " %arg-2% "
            send "Made %arg-1% execute %arg-2%"
        else:
            send "%{_noperms}%"

command /check <text>:
	usage: /check <player>
	permission: report.sut
	permission message: you are not admin
	trigger:
		send "&5===== REPORTS =====" to player
		send "&4%arg 1% &6have been reported &4%{report1.%arg 1%}% &6times"
		send "&4%arg 1% &6have reported other users &4%{report2.%arg 1%}% &6times"
command /report <player> <text>:
	usage: /report <player> <reason>
	trigger:
		if {report.cooldown.%player%} is false:
			add 1 to {report1.%arg 1%}
			add 1 to {report2.%player%}
			send "&6Report sent to all staff online" to player
			loop all players:
				if loop-player have permission "report.sut":
					send "&5===== &5REPORT =====" to loop-player
					send "&6Report by: %player%" to loop-player
					send "&6Player reported: %arg 1%" to loop-player
					send "&6Reason: %arg 2%" to loop-player
			set {report.cooldown.%player%} to true
			wait 30 seconds
			set {report.cooldown.%player%} to false
		if {report.cooldown.%player%} is true:
			send "&6Please wait before reporting again"
on join:
	set {report.cooldown.%player%} to false

command /setmotd <text>:
	permission: setmotd.sut
	description: Sets message of the day
	trigger:
		message "Set the MOTD to '%argument%<reset>'"
		set {motd} to argument

command /showmotd:
	description: Displays the message of the day
	trigger:
		message {motd}

on join:
	# uncomment the following line to make the MOTD appear after other messages
	# wait a tick
	message {motd}

command /sethome:
	description: Set your home
	executable by: players
	trigger:
		set {homes.%player%.location} to location of player
		message "Set your home to <grey>%location of player%<reset>"

command /home:
	description: Teleport yourself to your home
	executable by: players
	trigger:
		if {homes.%player%.location} is not set:
			message "You have not set your home yet!"
			stop trigger
		teleport player to {homes.%player%.location}