Forge download
KuroNeko87 opened this issue · 2 comments
KuroNeko87 commented
The links for the forge downloads are wrong.
forge: function(callback) {
var FORGE_VERSIONS_URL = 'http://files.minecraftforge.net/maven/net/minecraftforge/forge/promotions.json';
var path_prefix = path.join(base_dir, mineos.DIRS['profiles']);
function handle_reply(err, response, body) {
var p = [];
if (!err && (response || {}).statusCode === 200)
for (var index in body.promos) {
var item = new profile_template();
var ref_obj = body.promos[index];
item['id'] = index;
item['time'] = ref_obj['modified'];
item['releaseTime'] = ref_obj['modified'];
item['type'] = 'release';
item['group'] = 'forge';
item['webui_desc'] = 'Forge Jar (build {0})'.format(ref_obj['build']);
item['weight'] = 0;
item['filename'] = 'forge-{0}-{1}-installer.jar'.format(ref_obj['mcversion'], ref_obj['version']);
item['downloaded'] = fs.existsSync(path.join(base_dir, mineos.DIRS['profiles'], item.id, item.filename));
item['version'] = ref_obj['mcversion'];
item['release_version'] = ref_obj['version'];
item['url'] = 'http://files.minecraftforge.net/maven/net/minecraftforge/forge/{0}-{1}/{2}'.format(ref_obj['mcversion'], ref_obj['version'], item['filename']);
if (parseFloat(ref_obj['mcversion']) > 1.6)
p.push(item);
}
callback(err, p);
}
request({ url: FORGE_VERSIONS_URL, json: true }, handle_reply);
},
Should be:
forge: function(callback) {
var FORGE_VERSIONS_URL = 'http://files.minecraftforge.net/maven/net/minecraftforge/forge/promotions.json';
var path_prefix = path.join(base_dir, mineos.DIRS['profiles']);
function handle_reply(err, response, body) {
var p = [];
if (!err && (response || {}).statusCode === 200)
for (var index in body.promos) {
var item = new profile_template();
var ref_obj = body.promos[index];
item['id'] = index;
item['time'] = ref_obj['modified'];
item['releaseTime'] = ref_obj['modified'];
item['type'] = 'release';
item['group'] = 'forge';
item['webui_desc'] = 'Forge Jar (build {0})'.format(ref_obj['build']);
item['weight'] = 0;
item['filename'] = 'forge-{0}-{1}-{2}-installer.jar'.format(ref_obj['mcversion'], ref_obj['version'], ref_obj['mcversion']);
item['downloaded'] = fs.existsSync(path.join(base_dir, mineos.DIRS['profiles'], item.id, item.filename));
item['version'] = ref_obj['mcversion'];
item['release_version'] = ref_obj['version'];
item['url'] = 'http://files.minecraftforge.net/maven/net/minecraftforge/forge/{0}-{1}-{2}/{3}'.format(ref_obj['mcversion'], ref_obj['version'], ref_obj['mcversion'], item['filename']);
if (parseFloat(ref_obj['mcversion']) > 1.6)
p.push(item);
}
callback(err, p);
}
request({ url: FORGE_VERSIONS_URL, json: true }, handle_reply);
},
ghostsquad commented
can you submit a pull request?
hexparrot commented
This is for mineos-node, apparently, but has been added as an issue to the python mineos. If this is still relevant, please open the issue in mineos-node.