fallback if modification doesnt have the proper arguments

This commit is contained in:
Pierce 2019-04-06 13:03:01 -04:00
parent c767fb0685
commit dd8b80d69d
2 changed files with 4 additions and 2 deletions

View file

@ -256,9 +256,11 @@ module.exports.getLaunchOptions = function (version, modification, options) {
return new Promise(resolve => {
let type = modification || version;
const arguments = type.minecraftArguments ? type.minecraftArguments.split(' ') : type.arguments.game;
let arguments = type.minecraftArguments ? type.minecraftArguments.split(' ') : type.arguments.game;
const assetPath = version.assets === "legacy" || version.assets === "pre-1.6" ? path.join(options.root, 'assets', 'legacy') : path.join(options.root, 'assets');
if(arguments.length < 9) arguments = arguments.concat(version.minecraftArguments ? version.minecraftArguments.split(' ') : version.arguments.game);
const fields = {
'${auth_access_token}': options.authorization.access_token,
'${auth_session}': options.authorization.access_token,

View file

@ -1,6 +1,6 @@
{
"name": "minecraft-launcher-core",
"version": "2.5.0",
"version": "2.5.1",
"description": "Module that downloads Minecraft assets and runs Minecraft. Also Supports Forge",
"main": "index.js",
"dependencies": {