Fix npc loaders not having the affectsSpawning flag enabled (#29)

This commit is contained in:
OmerBenGera 2021-12-04 19:15:14 +02:00
parent 38c2c69281
commit 50653b1904
2 changed files with 7 additions and 1 deletions

View File

@ -1,7 +1,7 @@
group 'v1_8_R3'
dependencies {
compileOnly "org.spigotmc:v1_8_R3:latest"
compileOnly "org.spigotmc:v1_8_R3-Taco:latest"
compileOnly project(":API")
compileOnly parent
}

View File

@ -45,6 +45,12 @@ public final class ChunkLoaderNPC_v1_8_R3 extends EntityPlayer implements ChunkL
fauxSleeping = true;
try {
// Paper
affectsSpawning = true;
} catch (Throwable ignored) {
}
spawnIn(world);
setLocation(location.getX(), location.getY(), location.getZ(), location.getYaw(), location.getPitch());