Katton.makeAdminExecuteCommand
Katton.makeAdminExecuteCommand(command)
makes the current Skript admin run a command
requirements
- this only works in the
actual game. it mostly never works in a custom preset. trying it there does nothing except send you a blocked message (some commands still work but dont affect anyone else outside of your preset) - the command must be on the allow list (see below)
basic examples
Katton.makeAdminExecuteCommand("pvp true")
Katton.makeAdminExecuteCommand("broadcast hello")
worldedit commands
Katton.makeAdminExecuteCommand("//pos1 0,1,0")
Katton.makeAdminExecuteCommand("//pos2 10,1,10")
Katton.makeAdminExecuteCommand("//set stone")
Katton.makeAdminExecuteCommand("//replace stone air")
example: setting up an arena
@Katton.command(name = "setuparena", permission = "admin")
function setupArena(sender, args) {
Katton.makeAdminExecuteCommand("//pos1 0,1,0")
Katton.makeAdminExecuteCommand("//pos2 20,1,20")
Katton.makeAdminExecuteCommand("//set stone")
Katton.makeAdminExecuteCommand("//pos2 20,10,20")
Katton.makeAdminExecuteCommand("//walls glass")
sender.sendMessage("&aarena is set up!")
}
the full allow list
border, bring, bringall, broadcast, cleareffects, countdown, stopcd, crafting, creative,
cylinder, day, deathmessages, difficulty, togglesuicide, chatcooldown, dropping, falldamage,
freeze, hardcore, hardcorebeds, heal, healall, hideplayers, viewplayers, highlight, hunger,
iframes, interacting, keepinv, kill, killall, killmobs, mobdamage, mobspawning, mutechat,
mutespectators, nametags, naturalregen, night, oldcombat, pickup, platform, pve, pvp,
random, randomitems, reducedf3, respawntimer, setskin, setspawnpoint, spectator, survival,
team, title, tnt, winblock, autopickup, adminlock, to, goto, poll, placing, breaking,
building, clearplayer, blockattributes, elytradamage, reminder, autosmelt, hidehates, cyl,
//pos1, //pos2, //set, //undo, //replace, //center, //walls