public Chunk loadChunk(World var1, int var2, int var3) throws IOException {
      DataInputStream var4 = RegionFileCache.getChunkInputStream(this.worldDir, var2, var3);
      if(var4 != null) {
         NBTTagCompound var5 = CompressedStreamTools.func_1141_a(var4);
         if(!var5.hasKey("Level")) {
            System.out.println("Chunk file at " + var2 + "," + var3 + " is missing level data, skipping");
            return null;
         } else if(!var5.getCompoundTag("Level").hasKey("Blocks")) {
            System.out.println("Chunk file at " + var2 + "," + var3 + " is missing block data, skipping");
            return null;
         } else {
            Chunk var6 = ChunkLoader.loadChunkIntoWorldFromCompound(var1, var5.getCompoundTag("Level"));
            if(!var6.isAtLocation(var2, var3)) {
               System.out.println("Chunk file at " + var2 + "," + var3 + " is in the wrong location; relocating. (Expected " + var2 + ", " + var3 + ", got " + var6.xPosition + ", " + var6.zPosition + ")");
               var5.setInteger("xPos", var2);
               var5.setInteger("zPos", var3);
               var6 = ChunkLoader.loadChunkIntoWorldFromCompound(var1, var5.getCompoundTag("Level"));
            }

            var6.func_25124_i();
            return var6;
         }
      } else {
         return null;
      }
   }