Skip to content

Component Argument

Must be a valid JSON text component, returns net.kyori.adventure.text.Component. Example:

Kotlin
val audience = BukkitAudiences.create(this)
    StellarCommand("send-to-self")
        .addComponentArgument(name = "component")
        .addExecution<Player> {
            val component = getArgument<Component>("component")
            audience.sender(sender).sendMessage(component)
        }

Component Argument

Released under the MIT License.