From abbfb52c1b00ecff447d95de063358a81563a066 Mon Sep 17 00:00:00 2001 From: Daniel Scalzi Date: Sun, 19 Nov 2017 00:41:36 -0500 Subject: [PATCH] Fixed bug with hashless assets, updating distro index. --- app/assets/js/assetguard.js | 10 +- app/assets/js/launchprocess.js | 2 +- app/assets/js/script.js | 4 +- app/assets/westeroscraft.json | 96 +++++++---- app/assets/westeroscraft.xml | 282 +++++++++++++++++++++++++++++++-- 5 files changed, 344 insertions(+), 50 deletions(-) diff --git a/app/assets/js/assetguard.js b/app/assets/js/assetguard.js index d02b5ca..fbcbe12 100644 --- a/app/assets/js/assetguard.js +++ b/app/assets/js/assetguard.js @@ -261,11 +261,11 @@ function _parseChecksumsFile(content){ * @returns {Boolean} - true if the file exists and calculated hash matches the given hash, otherwise false. */ function _validateLocal(filePath, algo, hash){ - //No hash provided, have to assume it's good. - if(hash == null){ - return true - } if(fs.existsSync(filePath)){ + //No hash provided, have to assume it's good. + if(hash == null){ + return true + } let fileName = path.basename(filePath) let buf = fs.readFileSync(filePath) let calcdhash = _calculateHash(buf, algo) @@ -349,7 +349,7 @@ function _extractPackXZ(filePaths){ return new Promise(function(fulfill, reject){ const libPath = path.join(__dirname, '..', 'libraries', 'java', 'PackXZExtract.jar') const filePath = filePaths.join(',') - const child = child_process.spawn('C:\\Program Files\\Java\\jdk1.8.0_144\\bin\\javaw.exe', ['-jar', libPath, '-packxz', filePath]) + const child = child_process.spawn('C:\\Program Files\\Java\\jdk1.8.0_152\\bin\\javaw.exe', ['-jar', libPath, '-packxz', filePath]) child.stdout.on('data', (data) => { //console.log('PackXZExtract:', data.toString('utf8')) }) diff --git a/app/assets/js/launchprocess.js b/app/assets/js/launchprocess.js index db2c677..468695d 100644 --- a/app/assets/js/launchprocess.js +++ b/app/assets/js/launchprocess.js @@ -19,7 +19,7 @@ function launchMinecraft(versionData, forgeData, basePath){ //args.push('-mods modstore\\chatbubbles\\chatbubbles\\1.0.1_for_1.11.2\\mod_chatBubbles-1.0.1_for_1.11.2.litemod,modstore\\com\\westeroscraft\\westerosblocks\\3.0.0-beta-71\\westerosblocks-3.0.0-beta-71.jar,modstore\\mezz\\jei\\1.11.2-4.3.5.277\\jei-1.11.2-4.3.5.277.jar,modstore\\net\\optifine\\optifine\\1.11.2_HD_U_B9\\optifine-1.11.2_HD_U_B9.jar') //args.push('--modListFile absolute:C:\\Users\\Asus\\Desktop\\LauncherElectron\\app\\assets\\WesterosCraft-1.11.2.json') //TODO make this dynamic - const child = child_process.spawn('C:\\Program Files\\Java\\jdk1.8.0_144\\bin\\javaw.exe', args) + const child = child_process.spawn('C:\\Program Files\\Java\\jdk1.8.0_152\\bin\\javaw.exe', args) child.stdout.on('data', (data) => { console.log('Minecraft:', data.toString('utf8')) }) diff --git a/app/assets/js/script.js b/app/assets/js/script.js index 27253e9..421cc0a 100644 --- a/app/assets/js/script.js +++ b/app/assets/js/script.js @@ -31,10 +31,10 @@ document.onreadystatechange = function () { window.minimize() }) - /*document.getElementById("test_btn").addEventListener('click', function(e){ + document.getElementById("menu_button").addEventListener('click', function(e){ console.log('testing') testdownloads() - })*/ + }) } } diff --git a/app/assets/westeroscraft.json b/app/assets/westeroscraft.json index 607c79a..4ed4454 100644 --- a/app/assets/westeroscraft.json +++ b/app/assets/westeroscraft.json @@ -244,6 +244,75 @@ "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/jei.jar" } }, + { + "id": "mcp.mobius:waila:1.7.1_1.11.2", + "name": "Waila (1.7.1_1.11.2)", + "type": "forgemod", + "required": { + "value": false + }, + "artifact": { + "size": 542744, + "MD5": "26258a3557bf333e8f4ce8b1e9481031", + "extension": ".jar", + "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/Waila.jar" + } + }, + { + "id": "com.github.hexomod:worldeditcuife2:2.1.1-mf-1.11.2-13.20.0.2228", + "name": "WorldEditCUI (v2.1.1-mf-1.11.2-13.20.0.2228)", + "type": "forgemod", + "required": { + "value": false + }, + "artifact": { + "size": 461691, + "MD5": "439f82b69f3464969163c188818c677b", + "extension": ".jar", + "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/worldeditcuife.jar" + } + }, + { + "id": "techbrew:journeymap:1.11.2-5.4.7", + "name": "JourneyMap (1.11.2-5.4.7)", + "type": "forgemod", + "required": { + "value": false + }, + "artifact": { + "size": 1735525, + "MD5": "1c3380502eb7b9a495581b2402d144df", + "extension": ".jar", + "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/journeymap.jar" + } + }, + { + "id": "octarine-noise:betterfoliage:1.11.2-2.1.8", + "name": "BetterFoliage (1.11.2-2.1.8)", + "type": "forgemod", + "required": { + "value": false + }, + "artifact": { + "size": 4676029, + "MD5": "b2dd47e42da56fb49a07a0d38df91bc4", + "extension": ".jar", + "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/BetterFoliage.jar" + }, + "sub_modules": [ + { + "id": "betterfoliage.cfg", + "name": "BetterFoliage Configuration File", + "type": "file", + "artifact": { + "size": 7878, + "MD5": "6dd38f873c4129af05a2d6c500cbe954", + "path": "/config/betterfoliage.cfg", + "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/config/betterfoliage.cfg" + } + } + ] + }, { "id": "com.westeroscraft:westerosblocks:3.0.0-beta-6-133", "name": "WesterosBlocks (3.0.0-beta-6-133)", @@ -286,33 +355,6 @@ "path": "servers.dat", "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/servers.dat" } - }, - { - "id": "chatbubbles:chatbubbles:1.0.1_for_1.11.2", - "name": "Chat Bubbles 1.11.2", - "type": "litemod", - "required": { - "value": false - }, - "artifact": { - "size": 37838, - "MD5": "0497a93e5429b43082282e9d9119fcba", - "extension": ".litemod", - "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/mod_chatBubbles-1.0.1_for_1.11.2.litemod" - }, - "sub_modules": [ - { - "id": "customRegexes", - "name": "Custom Regexes for Chat Bubbles", - "type": "file", - "artifact": { - "size": 331, - "MD5": "f21b4b325f09238a3d6b2103d54351ef", - "path": "mods/chatbubbles/customRegexes.txt", - "url": "http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/customRegexes.txt" - } - } - ] } ] } diff --git a/app/assets/westeroscraft.xml b/app/assets/westeroscraft.xml index 417dcdf..1eec4d5 100644 --- a/app/assets/westeroscraft.xml +++ b/app/assets/westeroscraft.xml @@ -1,12 +1,13 @@ - - - http://files.minecraftforge.net/maven/net/minecraftforge/forge/1.11.2-13.20.0.2282/forge-1.11.2-13.20.0.2282-universal.jar + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/forge-1.11.2-13.20.1.2429-universal.jar true Library - 1d0f1b383ec122a993e374771c954be2 + 3fcc9b0104f0261397d3cc897e55a1c5 http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/launchwrapper-1.12.jar @@ -22,13 +23,13 @@ http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-library-2.11.1.jar.pack.xz - f2d0c1ce6ab76531bbd48acbcd3d4ff1 + 379c15c4f724421c6d5d7aecedaf87a6 true Library http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-compiler-2.11.1.jar.pack.xz - 9c88616e35796955e0ff1235b11f1475 + 7d89e952f2d5c74577310cd2c28e3f20 true Library @@ -70,13 +71,13 @@ http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-xml_2.11-1.0.2.jar.pack.xz - 1c5a20efca1474626e0e0123f9cdd8ce + cc891b094a4c32dedc56bfefe9b072ff true Library http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/akka-actor_2.11-2.3.3.jar.pack.xz - 469367f3308e571b1bdf2192d7779807 + 25cb22c3078e9fb3f7a861c912924862 true Library @@ -117,24 +118,275 @@ Library - + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/WesterosBlocks.jar + true + Regular + 5a89e2ab18916c18965fc93a0766cc6e + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/OptiFine.jar + true + Regular + 82f495594cd50e1fda7a8aa0246239fc + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/jei.jar + true + Regular + f4d931f6db6210621a86fa1e7eae8016 + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/Waila.jar + false + Regular + 26258a3557bf333e8f4ce8b1e9481031 + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/worldeditcuife.jar + false + Regular + 439f82b69f3464969163c188818c677b + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/journeymap.jar + false + Regular + 1c3380502eb7b9a495581b2402d144df + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/BetterFoliage.jar + false + Regular + b2dd47e42da56fb49a07a0d38df91bc4 + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/config/betterfoliage.cfg + /config/betterfoliage.cfg + 6dd38f873c4129af05a2d6c500cbe954 + + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/mods/DynamicSurroundings.jar + false + Regular + 82a6aac5420151960b8dd709deee5423 + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/config/dsurround/dsurround.cfg + /config/dsurround/dsurround.cfg + 4c64fc6cbbb83b18012ed4820b0b496e + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/config/dsurround/westeros.json + /config/dsurround/westeros.json + 44eab112ff24d0bd29974c270de868ba + + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/resourcepacks/WesterosCraft.zip + true + Regular + /resourcepacks/WesterosCraft.zip + ec2d9fdb14d5c2eafe5975a240202f1a + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/options-1.11.2.txt + /options.txt + true + + + http://mc.westeroscraft.com/WesterosCraftLauncher/prod-1.11.2/servers.dat + /servers.dat + 71d99e229d7d2b8d2a6423e46832a4b8 + + + + + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/forge-1.11.2-13.20.1.2476-universal.jar + true + Library + 7cef816cc01d53a04a180f0214d2982a + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/launchwrapper-1.12.jar + 934b2d91c7c5be4a49577c9e6b40e8da + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/asm-all-5.0.3.jar + c5cc4613bbdfba3ccf5f0ab85390d0b8 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-library-2.11.1.jar.pack.xz + 379c15c4f724421c6d5d7aecedaf87a6 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-compiler-2.11.1.jar.pack.xz + 7d89e952f2d5c74577310cd2c28e3f20 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-actors-migration_2.11-1.1.0.jar.pack.xz + 55e0dc48a2a122353628a463b9499cf0 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-continuations-library_2.11-1.0.2.jar.pack.xz + 820008ee6df308dafa0a6c478270aa19 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-continuations-plugin_2.11.1-1.0.2.jar.pack.xz + 657a7ad23928bf4bee68202c7d7e1d56 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-parser-combinators_2.11-1.0.1.jar.pack.xz + de496467c91610e55e6e711b6bdbf10c + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-reflect-2.11.1.jar.pack.xz + abbdaf710e856f6e65376706c9505952 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-swing_2.11-1.0.1.jar + 1d360289e697022a3f57abaad344b28f + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/scala-xml_2.11-1.0.2.jar.pack.xz + cc891b094a4c32dedc56bfefe9b072ff + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/akka-actor_2.11-2.3.3.jar.pack.xz + 25cb22c3078e9fb3f7a861c912924862 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/config-1.2.1.jar.pack.xz + f24b281c40daef1280d5ef26b11caa63 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/lzma-0.0.1.jar + a3e3c3186e41c4a1a3027ba2bb23cdc6 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/trove4j-3.0.3.jar + 8fc4d4e0129244f9fd39650c5f30feb2 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/vecmath-1.5.2.jar + e5d2b7f46c4800a32f62ce75676a5710 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/jopt-simple-4.6.jar + 13560a58a79b46b82057686543e8d727 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/files/1.11.2/MercuriusUpdater-1.11.2.jar + 13560a58a79b46b82057686543e8d727 + true + Library + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/WesterosBlocks.jar true Regular - 2a71c13afd289d15c9f95a23712b095d + 5a89e2ab18916c18965fc93a0766cc6e - + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/OptiFine.jar true Regular - 8c88f3b0e8b62088064814520e9d1c31 + 82f495594cd50e1fda7a8aa0246239fc - + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/jei.jar + true + Regular + f4d931f6db6210621a86fa1e7eae8016 + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/Waila.jar + false + Regular + 26258a3557bf333e8f4ce8b1e9481031 + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/worldeditcuife.jar + false + Regular + 439f82b69f3464969163c188818c677b + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/journeymap.jar + false + Regular + 1c3380502eb7b9a495581b2402d144df + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/BetterFoliage.jar + false + Regular + b2dd47e42da56fb49a07a0d38df91bc4 + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/config/betterfoliage.cfg + /config/betterfoliage.cfg + 6dd38f873c4129af05a2d6c500cbe954 + + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/mods/DynamicSurroundings.jar + false + Regular + 82a6aac5420151960b8dd709deee5423 + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/config/dsurround/dsurround.cfg + /config/dsurround/dsurround.cfg + 4c64fc6cbbb83b18012ed4820b0b496e + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/config/dsurround/westeros.json + /config/dsurround/westeros.json + 44eab112ff24d0bd29974c270de868ba + + + http://mc.westeroscraft.com/WesterosCraftLauncher/test-1.11.2/resourcepacks/WesterosCraft.zip true Regular /resourcepacks/WesterosCraft.zip - 1b5dd219a21bda8cd0fb8f7ee986515a + ec2d9fdb14d5c2eafe5975a240202f1a http://mc.westeroscraft.com/WesterosCraftLauncher/files/options-1.11.2.txt /options.txt @@ -146,6 +398,6 @@ 594de6063df993b5fde31c7290226ee4 - +