mirror of
https://github.com/artegoser/pimi-launcher-core.git
synced 2024-12-23 10:23:47 +03:00
Not sure how this worked when i tested this.. Fixed some dumb mistakes
This commit is contained in:
parent
f5e5482c5d
commit
b95ef6f9a2
2 changed files with 4 additions and 4 deletions
|
@ -106,7 +106,7 @@ module.exports.getAssets = function (directory, version) {
|
|||
}
|
||||
|
||||
// Seems taking it out of the initial download loop allows everything to be copied...
|
||||
if(version.assets === "legacy") {
|
||||
if(version.assets === "legacy" || version.assets === "pre-1.6") {
|
||||
for(const asset in index.objects) {
|
||||
const hash = index.objects[asset].hash;
|
||||
const subhash = hash.substring(0,2);
|
||||
|
@ -119,7 +119,7 @@ module.exports.getAssets = function (directory, version) {
|
|||
shelljs.mkdir('-p', path.join(directory, 'assets', 'legacy', legacyAsset.join('/')));
|
||||
}
|
||||
|
||||
if(!fs.existsSync(path.join(assetDirectory, hash), path.join(directory, 'assets', 'legacy', asset))) {
|
||||
if (!fs.existsSync(path.join(directory, 'assets', 'legacy', asset))) {
|
||||
fs.copyFileSync(path.join(assetDirectory, hash), path.join(directory, 'assets', 'legacy', asset))
|
||||
}
|
||||
}
|
||||
|
@ -244,7 +244,7 @@ module.exports.getLaunchOptions = function (version, forge, options) {
|
|||
return new Promise(resolve => {
|
||||
const type = forge || version;
|
||||
const arguments = type.minecraftArguments ? type.minecraftArguments.split(' ') : type.arguments.game;
|
||||
const assetPath = version.assets === "legacy" ? path.join(options.root, 'assets', 'legacy') : path.join(options.root, 'assets');
|
||||
const assetPath = version.assets === "legacy" || version.assets === "pre-1.6" ? path.join(options.root, 'assets', 'legacy') : path.join(options.root, 'assets');
|
||||
|
||||
const fields = {
|
||||
'${auth_access_token}': options.authorization.access_token,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "minecraft-launcher-core",
|
||||
"version": "2.4.1",
|
||||
"version": "2.4.2",
|
||||
"description": "Module that downloads Minecraft assets and runs Minecraft. Also Supports Forge",
|
||||
"main": "index.js",
|
||||
"dependencies": {
|
||||
|
|
Loading…
Add table
Reference in a new issue