Hello! I'm here to introduce one of my first basic but useful scripts (written in Skript). This script allows you to block and/or unblock any command you wish!
Features
- /block [insert command here without /]
- /unblock [insert command here without /]
- Fully configurable messages!
- Supports PermissionsEX system
- command.block
- command.unblock
- Minecraft version 1.7 through 1.10
- Skript 2.2 - Download HERE
- Download Skript 2.2 plugin from the link above
- Drop the .jar into your plugin folder
- Run your server
- A folder 'Skript' should be in your plugins folder
- Inside that folder, press 'scripts'
- Drop the .sk file inside that folder
- Run command /skript load Book Commands
Code
Code:
options:
# // CONFIGURABLE MESSAGES
desc: &4Allows to block any command!
desc2: &4Allows to unblock any blocked command!
commandBlocked: &4You have blocked the command!
alreadyBlocked: &4This command is already blocked!
listblockedCommands: &4Blocked commands: &6%{blockedcommands::*}%
commandisBlocked: &4This command is blocked!
specifyCommand: &4You must specify a command!
commandisnotBlocked: &4This command is not blocked!
# // CHANGE PERMISSIONS BELOW HERE
permissiontoblock: command.block
permissiontounblock: command.unblock
permissionmessage: &4You do not have permission!
# // Do not EDIT anything below!
command /block <text>:
description: {@desc}
permission: {@permissiontoblock}
permission message: {@permissionmessage}
trigger:
if arg-1 is set:
if {blockedcommands::*} contains "%arg-1%":
send "{@alreadyBlocked}"
else:
add argument-1 to {blockedcommands::*}
send "{@commandBlocked}"
send "{@listblockedCommands}"
else:
send "{@specifyCommand}"
command /unblock <text>:
description: {@desc2}
permission: {@permissiontounblock}
permission message: {@permissionmessage}
trigger:
if arg-1 is set:
remove "%arg-1%" from {blockedcommands::*}
send "{@listblockedCommands}"
else:
send "{@specifyCommand}"
on command:
loop {blockedcommands::*}:
if command is loop-value:
cancel event
send "{@commandisBlocked}"
stop loop
Blocking a command:
Unblocking a command:
If you like it, let me know.
And also if you want to tell me how shitty it is, I'd love to know.
But enjoy! (for those who use it)
Last edited:
