update to 1.18.2

This commit is contained in:
l4zs
2022-03-19 16:12:00 +01:00
parent e12be89c50
commit 3c9a7edfa1
10 changed files with 203 additions and 209 deletions

View File

@@ -108,7 +108,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_R1.CraftWorld ?: return null
val craftWorld = world as? org.bukkit.craftbukkit.v1_18_R2.CraftWorld ?: return null
return craftWorld.createEntity(this, entityType.entityClass)?.let {
craftWorld.handle.addFreshEntity(it)
return@let it.bukkitEntity