KSpigot 1.19 (#50)
* Use new papermc repo url * Update gradle plugins * Update paper dependencies to 1.19 and bump version * Package renames * Update to kotlin 1.7.0 * Update kotlinx-serialization-json to 1.3.3 * Update kotlinx-coroutines to 1.6.2 * Correct version bump * Update versions in gradle_example.md * update some guide stuff Co-authored-by: l4zs <business@l4zs.de>
This commit is contained in:
@@ -33,7 +33,7 @@ object BrigardierSupport {
|
||||
}
|
||||
|
||||
@Suppress("HasPlatformType")
|
||||
fun resolveCommandManager() = (server as org.bukkit.craftbukkit.v1_18_R2.CraftServer)
|
||||
fun resolveCommandManager() = (server as org.bukkit.craftbukkit.v1_19_R1.CraftServer)
|
||||
.server.vanillaCommandDispatcher
|
||||
|
||||
internal fun registerAll() {
|
||||
@@ -52,7 +52,7 @@ object BrigardierSupport {
|
||||
fun updateCommandTree() {
|
||||
onlinePlayers.forEach {
|
||||
// send the command tree
|
||||
resolveCommandManager().sendCommands((it as org.bukkit.craftbukkit.v1_18_R2.entity.CraftPlayer).handle)
|
||||
resolveCommandManager().sendCommands((it as org.bukkit.craftbukkit.v1_19_R1.entity.CraftPlayer).handle)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -4,8 +4,8 @@ package net.axay.kspigot.data
|
||||
|
||||
import net.axay.kspigot.annotations.NMS_General
|
||||
import net.minecraft.nbt.CompoundTag
|
||||
import org.bukkit.craftbukkit.v1_18_R2.entity.CraftEntity
|
||||
import org.bukkit.craftbukkit.v1_18_R2.inventory.CraftItemStack
|
||||
import org.bukkit.craftbukkit.v1_19_R1.entity.CraftEntity
|
||||
import org.bukkit.craftbukkit.v1_19_R1.inventory.CraftItemStack
|
||||
import org.bukkit.entity.Entity
|
||||
import org.bukkit.inventory.ItemStack
|
||||
|
||||
|
@@ -138,7 +138,7 @@ fun Player.showOnlinePlayers() {
|
||||
@Deprecated("This function is unstable and it cannot be guaranteed that it will work at any time in the future.")
|
||||
@NMS_General
|
||||
fun Location.spawnCleanEntity(entityType: EntityType): Entity? {
|
||||
val craftWorld = world as? org.bukkit.craftbukkit.v1_18_R2.CraftWorld ?: return null
|
||||
val craftWorld = world as? org.bukkit.craftbukkit.v1_19_R1.CraftWorld ?: return null
|
||||
return craftWorld.createEntity(this, entityType.entityClass)?.let {
|
||||
craftWorld.handle.addFreshEntity(it)
|
||||
return@let it.bukkitEntity
|
||||
|
@@ -10,7 +10,7 @@ import org.bukkit.Location
|
||||
import org.bukkit.Material
|
||||
import org.bukkit.block.Block
|
||||
import org.bukkit.block.data.BlockData
|
||||
import org.bukkit.craftbukkit.v1_18_R2.entity.CraftEntity
|
||||
import org.bukkit.craftbukkit.v1_19_R1.entity.CraftEntity
|
||||
import org.bukkit.entity.Entity
|
||||
import org.bukkit.entity.EntityType
|
||||
|
||||
|
Reference in New Issue
Block a user