It compiles

This commit is contained in:
Mariell Hoversholm
2021-03-16 16:50:45 +01:00
parent 908c938d0c
commit 0750bfaf8c
92 changed files with 959 additions and 135 deletions

View File

@@ -17,7 +17,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ // Paper start - Provide fast information methods
+ public int getEntityCount() {
+ int ret = 0;
+ for (net.minecraft.server.Entity entity : world.entitiesById.values()) {
+ for (net.minecraft.world.entity.Entity entity : world.entitiesById.values()) {
+ if (entity.isChunkLoaded()) {
+ ++ret;
+ }
@@ -28,8 +28,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ // We don't use the full world tile entity list, so we must iterate chunks
+ Long2ObjectLinkedOpenHashMap<PlayerChunk> chunks = world.getChunkProvider().playerChunkMap.visibleChunks;
+ int size = 0;
+ for (net.minecraft.server.PlayerChunk playerchunk : chunks.values()) {
+ net.minecraft.server.Chunk chunk = playerchunk.getChunk();
+ for (PlayerChunk playerchunk : chunks.values()) {
+ net.minecraft.world.level.chunk.Chunk chunk = playerchunk.getChunk();
+ if (chunk == null) {
+ continue;
+ }