From d79c3263073d55b26f36100184283ff40bf23a99 Mon Sep 17 00:00:00 2001 From: Bixilon Date: Sun, 24 Apr 2022 20:53:05 +0200 Subject: [PATCH] fix build with newer yarn mappings --- src/main/kotlin/de/bixilon/pixlyzer/EntitySpawner.kt | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/main/kotlin/de/bixilon/pixlyzer/EntitySpawner.kt b/src/main/kotlin/de/bixilon/pixlyzer/EntitySpawner.kt index b971eee..dde6ca4 100644 --- a/src/main/kotlin/de/bixilon/pixlyzer/EntitySpawner.kt +++ b/src/main/kotlin/de/bixilon/pixlyzer/EntitySpawner.kt @@ -30,7 +30,7 @@ object EntitySpawner { private val POTION_ENTITY_ENTITY_CLASS = getClass("net.minecraft.entity.thrown.ThrownPotionEntity", "net.minecraft.entity.projectile.thrown.PotionEntity")!! - private val ATOMIC_RANDOM_CLASS = getClass("net.minecraft.world.gen.random.AtomicSimpleRandom") + private val ATOMIC_RANDOM_CLASS = getClass("net.minecraft.util.math.random.AtomicSimpleRandom", "net.minecraft.world.gen.random.AtomicSimpleRandom") fun summonEntity(entityType: EntityType<*>): Entity { when (entityType) { @@ -81,12 +81,6 @@ object EntitySpawner { null } - private val LEGACY_ENTITY_CREATE_METHOD = try { - getClass("net.minecraft.entity.EntityType\$EntityFactory")?.getDeclaredMethod("create", EntityType::class.java, World::class.java) - } catch (exception: Exception) { - null - } - var OBJENSIS: Objenesis = ObjenesisStd() val CLIENT_LEVEL = OBJENSIS.newInstance(levelClass) as ClientWorld