From 5bf2e814060b364f541108370bf72de935bd18f0 Mon Sep 17 00:00:00 2001 From: holly Date: Fri, 27 Aug 2021 00:15:02 +0100 Subject: [PATCH] pre alloc chunk header --- server/Workers/ChunkWorker.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Workers/ChunkWorker.js b/server/Workers/ChunkWorker.js index 6dba0d2..10298fc 100644 --- a/server/Workers/ChunkWorker.js +++ b/server/Workers/ChunkWorker.js @@ -50,7 +50,7 @@ function generateChunk() { } function doChunk(chunk) { - const writer = new bufferStuff.Writer(); + const writer = new bufferStuff.Writer(18); writer.writeByte(0x33); // Chunk writer.writeInt(chunk[0] << 4); // Chunk X