From 6479aad437fe4ddf53ba112c6fe2275156ecd3b4 Mon Sep 17 00:00:00 2001 From: holly Date: Sat, 21 Aug 2021 08:22:09 +0100 Subject: [PATCH] reduce thread pool threads for the world --- config.json | 2 +- server/chunkManager.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config.json b/config.json index 36d7812..6857630 100644 --- a/config.json +++ b/config.json @@ -1,4 +1,4 @@ { "port": 25565, - "threadPoolCount": 8 + "worldThreads": 4 } \ No newline at end of file diff --git a/server/chunkManager.js b/server/chunkManager.js index f4de9f1..598dba8 100644 --- a/server/chunkManager.js +++ b/server/chunkManager.js @@ -17,7 +17,7 @@ module.exports = class { this.toRemove = []; // WoAh!!! Thread pool in js!?!??!???!11!?!?! - for (let i = 0; i < config.threadPoolCount; i++) { + for (let i = 0; i < config.worldThreads; i++) { const worker = new Worker(workerPath); this.threadPool.push([false, worker]); const myID = i;