From b59a4b74df596882e0874c338773ed8cae9e3c19 Mon Sep 17 00:00:00 2001 From: Pierce Date: Sun, 12 Jun 2022 16:03:22 -0700 Subject: [PATCH] HOTFIX 1.19 support --- components/handler.js | 4 +++- package.json | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/components/handler.js b/components/handler.js index c3e2358..788347c 100644 --- a/components/handler.js +++ b/components/handler.js @@ -229,7 +229,7 @@ class Handler { return true } } else { - if (lib.rules[0].action === 'allow' && lib.rules[0].os) return this.getOS() !== 'osx' + if (lib.rules[0].action === 'allow' && lib.rules[0].os) return lib.rules[0].os.name !== this.getOS() } } else { return false @@ -239,6 +239,8 @@ class Handler { async getNatives () { const nativeDirectory = path.resolve(this.options.overrides.natives || path.join(this.options.root, 'natives', this.version.id)) + if (parseInt(this.version.id.split('.')[1]) >= 19) return this.options.overrides.cwd || this.options.root + if (!fs.existsSync(nativeDirectory) || !fs.readdirSync(nativeDirectory).length) { fs.mkdirSync(nativeDirectory, { recursive: true }) diff --git a/package.json b/package.json index 82a5cf4..a48a9ec 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "minecraft-launcher-core", - "version": "3.16.12", + "version": "3.16.13", "description": "Lightweight module that downloads and runs Minecraft using javascript / NodeJS", "main": "index.js", "dependencies": {