Skip to content

Commit 68d8dd0

Browse files
refactor: replace playerArgument with entitySelectorArgumentOnePlayer in NPC teleport commands and bump plugin version to 1.21.11-1.5.3-SNAPSHOT
1 parent 8bfd9ec commit 68d8dd0

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ buildscript {
66
maven("https://repo.slne.dev/repository/maven-public/") { name = "maven-public" }
77
}
88
dependencies {
9-
classpath("dev.slne.surf:surf-api-gradle-plugin:1.21.10+")
9+
classpath("dev.slne.surf:surf-api-gradle-plugin:1.21.11+")
1010
}
1111
}
1212

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
kotlin.code.style=official
22
kotlin.stdlib.default.dependency=false
33
org.gradle.parallel=true
4-
version=1.21.10-1.5.0-SNAPSHOT
4+
version=1.21.11-1.5.3-SNAPSHOT

surf-npc-bukkit/src/main/kotlin/dev/slne/surf/npc/bukkit/command/sub/NpcTeleportHereCommand.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
package dev.slne.surf.npc.bukkit.command.sub
22

33
import dev.jorel.commandapi.CommandAPICommand
4+
import dev.jorel.commandapi.kotlindsl.entitySelectorArgumentOnePlayer
45
import dev.jorel.commandapi.kotlindsl.getValue
5-
import dev.jorel.commandapi.kotlindsl.playerArgument
66
import dev.jorel.commandapi.kotlindsl.playerExecutor
77
import dev.jorel.commandapi.kotlindsl.subcommand
88

@@ -15,7 +15,7 @@ import org.bukkit.entity.Player
1515
fun CommandAPICommand.npcTeleportHereCommand() = subcommand("teleporthere") {
1616
withPermission(PermissionRegistry.COMMAND_NPC_TELEPORT_HERE)
1717
npcArgument("npc")
18-
playerArgument("target", true)
18+
entitySelectorArgumentOnePlayer("target", true)
1919
playerExecutor { player, args ->
2020
val npc: Npc by args
2121
val target: Player? by args

surf-npc-bukkit/src/main/kotlin/dev/slne/surf/npc/bukkit/command/sub/NpcTeleportToCommand.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
package dev.slne.surf.npc.bukkit.command.sub
22

33
import dev.jorel.commandapi.CommandAPICommand
4+
import dev.jorel.commandapi.kotlindsl.entitySelectorArgumentOnePlayer
45
import dev.jorel.commandapi.kotlindsl.getValue
5-
import dev.jorel.commandapi.kotlindsl.playerArgument
66
import dev.jorel.commandapi.kotlindsl.playerExecutor
77
import dev.jorel.commandapi.kotlindsl.subcommand
88

@@ -18,7 +18,7 @@ import org.bukkit.entity.Player
1818
fun CommandAPICommand.npcTeleportToCommand() = subcommand("teleportto") {
1919
withPermission(PermissionRegistry.COMMAND_NPC_TELEPORT_TO)
2020
npcArgument("npc")
21-
playerArgument("target", true)
21+
entitySelectorArgumentOnePlayer("target", true)
2222
playerExecutor { player, args ->
2323
val npc: Npc by args
2424
val target: Player? by args

0 commit comments

Comments
 (0)