Skip to content

Release v1.1.0

Latest
Compare
Choose a tag to compare
@sya-ri sya-ri released this 21 May 14:20
1.1.0
08e9e5f

Full Changelog: 1.0.0...1.1.0


Compatible with CommandAPI v9.4.1

Changes

Support CommandAPI v9.4.1 features.

commandTree

Support the namespace argument.

inline fun commandTree(
    name: String,
    namespace: String,
    tree: CommandTree.() -> Unit = {
    },
)

inline fun commandTree(
    name: String,
    namespace: JavaPlugin,
    tree: CommandTree.() -> Unit = {
    },
)

entitySelectorArgument

Support the allowEmpty argument.

inline fun CommandTree.entitySelectorArgumentManyEntities(
    nodeName: String,
    allowEmpty: Boolean = true,
    crossinline block: Argument<*>.((CommandArguments) -> Collection<Entity>) -> Unit = {},
)

inline fun CommandTree.entitySelectorOptionalArgumentManyEntities(
    nodeName: String,
    allowEmpty: Boolean = true,
    crossinline block: Argument<*>.((CommandArguments) -> Collection<Entity>?) -> Unit = {},
)

inline fun CommandTree.entitySelectorArgumentManyPlayers(
    nodeName: String,
    allowEmpty: Boolean = true,
    crossinline block: Argument<*>.((CommandArguments) -> Collection<Player>) -> Unit = {},
)

inline fun CommandTree.entitySelectorOptionalArgumentManyPlayers(
    nodeName: String,
    allowEmpty: Boolean = true,
    crossinline block: Argument<*>.((CommandArguments) -> Collection<Player>?) -> Unit = {},
)

potionEffectNamespacedKeyArgument

Support to use NamespacedKey of potionEffectArgument.

inline fun CommandTree.potionEffectNamespacedKeyArgument(
    nodeName: String,
    crossinline block: Argument<*>.((CommandArguments) -> NamespacedKey) -> Unit = {},
)

inline fun CommandTree.potionEffectNamespacedKeyOptionalArgument(
    nodeName: String,
    crossinline block: Argument<*>.((CommandArguments) -> NamespacedKey?) -> Unit = {},
)

Installation

repositories {
    mavenCentral()
}

dependencies {
    implementation("dev.s7a:commandapi-bukkit-kotlin-improved:1.1.0")
}