Skip to content

Tutorial Commands

Shane Bee edited this page Jan 29, 2026 · 12 revisions

HySkript allows you to create custom commands for your Hytale Server.
If you have ever used Skript before, this will be mostly familiar to you.

Structure:

You can define commands along with a description, permission, trigger and sub commands.

[type] command /name (arguments):
    description: "A description for your command"
    permission: some.perm.for.your.command
    trigger:
        do some stuff

Let's break that down:

  • Type: You can leaves this blank (to make a global command) or use global, player or world.
  • Name: This is the name of your command.
  • Arguments: See arguments below.
  • Description: This is the description that will show up in the Hytale command GUI.
  • Permission: This is the permission a player is required to have to use this command.
  • Trigger: This is the section of code that will run when your command is executed.

Arguments:

You can add arguments to your commands to gather more input from the command executor.

Argument setup:

[<name:type:"description">]

  • Name: This is the name of your argument that will show up in the Hytale command GUI [optional].
    • This is optional, if excluded the name will match the type.
    • This is also used to create a local variable from this argument to be used within your trigger.
    • If excluded the variable will be created from the name of the type. If you have more than 1 type you will get extra numbers:
      • {_string} and {_string2}
  • Type: This is the type of argument, see Argument Types (required).
  • Description: This is the description used in the Hytale command GUI [optional].
  • [<>] = Optional argument
  • <> = Required argument

Examples:

player command /nickname <name:string:"New nickname to use">:
    trigger:
        set {nicknames::%uuid of context-player%} to {_name}

This would be typed in game as /nickname MrBean

player command /nickname [<name:string:"New nickname to use">]:
    trigger:
        if {_name} is set:
            set {nicknames::%uuid of context-player%} to {_name}
        else:
            delete {nicknames::%uuid of context-player%}

Now having an optional arg, we have two options:
/nickname = Will reset/remove the player's nickname
/nickname --name MrBean = Will set the player's nickname to "MrBean"

How it will look in game:
Screenshot 2026-01-29 at 8 36 07 AM

Sub Commands:

HySkript allows you to create sub commands.
This acts like a command within a command, executing different triggers depending on what is typed in the command.

Structure:

sub command /name (arguments)
This is basically the same as creating a command, except we replace the type with sub.
The type will default to patching the parent command.
For (arguments) see arguments above.

Examples:

player command /kill:
    sub command allplayers:
        trigger:
            kill all players
    trigger:
        kill player

Execution:
/kill = Will kill the executing player.
/kill allplayers = Will kill all players.

How it will look in game:
Screenshot 2026-01-29 at 8 33 53 AM

Examples:

A simple home command:

player command /home <name:string:"Name of home to teleport to">:
    sub command /set <name:string:"Name of home to teleport to">:
        description: "Set a home to your current location"
        permission: homes.command.home.set
        trigger:
            set {homes::%uuid of player%::%{_name}%} to location of player
            send "Your home '%{_name}%' has been set"
    description: "Teleport to a set home"
    permission: homes.command.home
    trigger:
        if {homes::%uuid of player%::%{_name}%} is set:
            teleport player to {homes::%uuid of player%::%{_name}%} 
        else:
            send "You don't have a home set for %{_name}%"

In game visual:
Screenshot 2026-01-29 at 8 45 13 AM Screenshot 2026-01-29 at 8 45 21 AM

Clone this wiki locally