Performant fictional entities

- Fixed crash with the Performant mod when entities are present in a ponder scene
This commit is contained in:
simibubi 2021-04-03 19:30:38 +02:00
parent 747849d52e
commit 1fd6b4360c
2 changed files with 5 additions and 1 deletions

View file

@ -1,6 +1,7 @@
package com.simibubi.create.content.schematics;
import com.simibubi.create.Create;
import com.simibubi.create.foundation.utility.worldWrappers.WrappedChunkProvider;
import com.simibubi.create.foundation.utility.worldWrappers.WrappedWorld;
import net.minecraft.block.AbstractFurnaceBlock;
import net.minecraft.block.Block;
@ -42,7 +43,7 @@ public class SchematicWorld extends WrappedWorld implements IServerWorld {
}
public SchematicWorld(BlockPos anchor, World original) {
super(original);
super(original, new WrappedChunkProvider());
this.blocks = new HashMap<>();
this.tileEntities = new HashMap<>();
this.bounds = new MutableBoundingBox();

View file

@ -54,6 +54,9 @@ public class WrappedChunkProvider extends AbstractChunkProvider {
public WrappedChunk getChunk(int x, int z) {
long pos = ChunkPos.asLong(x, z);
if (chunks == null)
return null;
WrappedChunk chunk = chunks.get(pos);