Launcher Forge 1.6.2
-
J’ai créé un launcher 1.6.2, je lui fait télécharger des fichiers Forge, il télécharge tout et après il me met cette erreure:
Launcher 1.0.8 (through bootstrap 4) started on windows… System.getProperty('os.name') == 'Windows 8' System.getProperty('os.version') == '6.2' System.getProperty('os.arch') == 'amd64' System.getProperty('java.version') == '1.7.0_25' System.getProperty('java.vendor') == 'Oracle Corporation' Loaded 1 profile(s); selected 'Essential-craft' Trying to log in... Logging in with access token Logged in successfully Delta time to compare resources: 456 ms Download job 'Resources' skipped as there are no files to download Job 'Resources' finished successfully Getting syncinfo for selected version Queueing library & version downloads Installed PartialVersion{id='1.6.2', updateTime=Fri Sep 13 13:00:51 CEST 2013, releaseTime=Fri Sep 13 13:00:51 CEST 2013, type=RELEASE} Download job 'Version & Libraries' started (8 threads, 27 files) Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\libraryjavasound\20101123\libraryjavasound-20101123.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl\2.9.0\lwjgl-2.9.0.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl_util\2.9.0\lwjgl_util-2.9.0.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\codecwav\20101023\codecwav-20101023.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\minecraft\launchwrapper\1.3\launchwrapper-1.3.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\soundsystem\20120107\soundsystem-20120107.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\java\jinput\jinput-platform\2.0.5\jinput-platform-2.0.5-natives-windows.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\google\code\gson\gson\2.2.2\gson-2.2.2.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\commons-io\commons-io\2.4\commons-io-2.4.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl-platform\2.9.0\lwjgl-platform-2.9.0-natives-windows.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\lzma\lzma\0.0.1\lzma-0.0.1.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\java\jinput\jinput\2.0.5\jinput-2.0.5.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\ow2\asm\asm-all\4.1\asm-all-4.1.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl\2.9.0\lwjgl-2.9.0.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\argo\argo\2.25_fixed\argo-2.25_fixed.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\codecjorbis\20101023\codecjorbis-20101023.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\java\jutils\jutils\1.0.0\jutils-1.0.0.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl_util\2.9.0\lwjgl_util-2.9.0.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\google\guava\guava\14.0\guava-14.0.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\apache\commons\commons-lang3\3.1\commons-lang3-3.1.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\bouncycastle\bcprov-jdk15on\1.47\bcprov-jdk15on-1.47.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\sf\jopt-simple\jopt-simple\4.5\jopt-simple-4.5.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\librarylwjglopenal\20100824\librarylwjglopenal-20100824.jar for job 'Version & Libraries': Used own copy as it matched etag Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\versions\1.6.2-Forge9.10.1.871\1.6.2-Forge9.10.1.871.jar for job 'Version & Libraries': Didn't have etag so assuming our copy is good Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\minecraftforge\minecraftforge\9.10.1.871\minecraftforge-9.10.1.871.jar for job 'Version & Libraries': Didn't have etag so assuming our copy is good Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\scala-lang\scala-library\2.10.2\scala-library-2.10.2.jar for job 'Version & Libraries': Didn't have etag so assuming our copy is good Finished downloading C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\scala-lang\scala-compiler\2.10.2\scala-compiler-2.10.2.jar for job 'Version & Libraries': Didn't have etag so assuming our copy is good Job 'Version & Libraries' finished successfully Launching game Looking for old natives to clean up... Unpacking natives to C:\Users\Pierre\AppData\Roaming\.Essential-craft\versions\1.6.2-Forge9.10.1.871\1.6.2-Forge9.10.1.871-natives-79942467162966 Launching in C:\Users\Pierre\AppData\Roaming\.Essential-craft Running C:\Program Files\Java\jre7\bin\javaw.exe -Xmx1G -Dfml.ignoreInvalidMinecraftCertificates=true -Dfml.ignorePatchDiscrepancies=true -Djava.library.path=C:\Users\Pierre\AppData\Roaming\.Essential-craft\versions\1.6.2-Forge9.10.1.871\1.6.2-Forge9.10.1.871-natives-79942467162966 -cp C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\minecraftforge\minecraftforge\9.10.1.871\minecraftforge-9.10.1.871.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\minecraft\launchwrapper\1.3\launchwrapper-1.3.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\ow2\asm\asm-all\4.1\asm-all-4.1.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\scala-lang\scala-library\2.10.2\scala-library-2.10.2.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\scala-lang\scala-compiler\2.10.2\scala-compiler-2.10.2.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\sf\jopt-simple\jopt-simple\4.5\jopt-simple-4.5.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\lzma\lzma\0.0.1\lzma-0.0.1.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\codecjorbis\20101023\codecjorbis-20101023.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\codecwav\20101023\codecwav-20101023.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\libraryjavasound\20101123\libraryjavasound-20101123.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\librarylwjglopenal\20100824\librarylwjglopenal-20100824.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\paulscode\soundsystem\20120107\soundsystem-20120107.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl\2.9.0\lwjgl-2.9.0.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl_util\2.9.0\lwjgl_util-2.9.0.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\argo\argo\2.25_fixed\argo-2.25_fixed.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\bouncycastle\bcprov-jdk15on\1.47\bcprov-jdk15on-1.47.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\google\guava\guava\14.0\guava-14.0.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\apache\commons\commons-lang3\3.1\commons-lang3-3.1.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\commons-io\commons-io\2.4\commons-io-2.4.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\java\jinput\jinput\2.0.5\jinput-2.0.5.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\net\java\jutils\jutils\1.0.0\jutils-1.0.0.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\com\google\code\gson\gson\2.2.2\gson-2.2.2.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl\2.9.0\lwjgl-2.9.0.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\libraries\org\lwjgl\lwjgl\lwjgl_util\2.9.0\lwjgl_util-2.9.0.jar;C:\Users\Pierre\AppData\Roaming\.Essential-craft\versions\1.6.2-Forge9.10.1.871\1.6.2-Forge9.10.1.871.jar net.minecraft.launchwrapper.Launch --username pierreti --session token:7d2390cb4d0e4304bf23c9409fda5920:7402c6dd88f6460099f8cf05d63bda6f --version 1.6.2-Forge9.10.1.871 --gameDir C:\Users\Pierre\AppData\Roaming\.Essential-craft --assetsDir C:\Users\Pierre\AppData\Roaming\.Essential-craft\assets --tweakClass cpw.mods.fml.common.launcher.FMLTweaker ---- YOU CAN CLOSE THIS LAUNCHER IF THE GAME STARTED OK ---- ---- YOU CAN CLOSE THIS LAUNCHER IF THE GAME STARTED OK ---- ---- YOU CAN CLOSE THIS LAUNCHER IF THE GAME STARTED OK ---- ---- (We'll do this automatically later ;D) ---- Client> sept. 28, 2013 8:30:22 PM net.minecraft.launchwrapper.LogWrapper log Client> INFO: Using tweak class name cpw.mods.fml.common.launcher.FMLTweaker Client> 2013-09-28 20:30:22 [INFO] [ForgeModLoader] Forge Mod Loader version 6.2.62.871 for Minecraft 1.6.2 loading Client> 2013-09-28 20:30:22 [INFO] [ForgeModLoader] Java is Java HotSpot(TM) 64-Bit Server VM, version 1.7.0_25, running on Windows 8:amd64:6.2, installed at C:\Program Files\Java\jre7 Client> 2013-09-28 20:30:22 [INFO] [STDOUT] Loaded 39 rules from AccessTransformer config file fml_at.cfg Client> 2013-09-28 20:30:22 [INFO] [STDOUT] Loaded 107 rules from AccessTransformer config file forge_at.cfg Client> 2013-09-28 20:30:24 [INFO] [ForgeModLoader] Found valid fingerprint for Minecraft Forge. Certificate fingerprint e3c3d50c7c986df74c645c0ac54639741c90a557 Client> 2013-09-28 20:30:24 [INFO] [STDOUT] A CRITICAL PROBLEM OCCURED INITIALIZING MINECRAFT - LIKELY YOU HAVE AN INCORRECT VERSION FOR THIS FML Client> 2013-09-28 20:30:24 [SEVERE] [ForgeModLoader] Unable to launch Client> java.lang.RuntimeException: java.lang.reflect.InvocationTargetException Client> at cpw.mods.fml.relauncher.CoreModManager.injectTransformers(CoreModManager.java:463) Client> at cpw.mods.fml.relauncher.FMLLaunchHandler.injectPostfixTransformers(FMLLaunchHandler.java:108) Client> at cpw.mods.fml.relauncher.FMLLaunchHandler.appendCoreMods(FMLLaunchHandler.java:113) Client> at cpw.mods.fml.common.launcher.FMLTweaker.injectIntoClassLoader(FMLTweaker.java:80) Client> at net.minecraft.launchwrapper.Launch.launch(Launch.java:51) Client> at net.minecraft.launchwrapper.Launch.main(Launch.java:18) Client> Caused by: java.lang.reflect.InvocationTargetException Client> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) Client> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) Client> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) Client> at java.lang.reflect.Method.invoke(Unknown Source) Client> at cpw.mods.fml.relauncher.CoreModManager.injectTransformers(CoreModManager.java:456) Client> … 5 more Client> Caused by: java.lang.NoClassDefFoundError: net/minecraft/crash/CallableMinecraftVersion Client> at cpw.mods.fml.common.Loader.<init>(Loader.java:184) Client> at cpw.mods.fml.common.Loader.instance(Loader.java:163) Client> ... 10 more Client> Caused by: java.lang.ClassNotFoundException: net.minecraft.crash.CallableMinecraftVersion Client> at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:179) Client> at java.lang.ClassLoader.loadClass(Unknown Source) Client> at java.lang.ClassLoader.loadClass(Unknown Source) Client> ... 12 more Client> Caused by: java.lang.NullPointerException Client> at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:171) Client> ... 14 more Game ended with no troubles detected (exit code 0) Deleting C:\Users\Pierre\AppData\Roaming\.Essential-craft\versions\1.6.2-Forge9.10.1.871\1.6.2-Forge9.10.1.871-natives-79942467162966
Et voici la disposition de mes fichiers dans mon FTP: http://essential-craft.hol.es/
Merci</init> -
Pour les logs, utilise code plutôt que java, la balise java n’est que la pour les codes.
FML ne trouve pas une classe de Minecraft, c’est étrange. Dans les paramètres de lancement tu as mit :-Dfml.ignoreInvalidMinecraftCertificates=true -Dfml.ignorePatchDiscrepancies=true
As-tu modifié le minecraft.jar ?
Aussi dans tes logs je vois Forge9.10.1.871, or sur ton ftp, c’est le 859 … -
J’ai encore l’erreure, et comment je fait pour modifier les paramètres de lancement ?
EDIT: Ok cette fois il fonctionne, j’avais juste mis un mauvais Forge, mais il ne télécharge pas les mods et pourtant le lien dans mon custom.jar est bon:package custom; public class Custom { public final static String urlNews = "http://essential-craft.com"; // "http://mcupdate.tumblr.com" public final static String urlDownload = "http://www.essential-craft.hol.es/essential-craft.download/"; // url de download des versions public final static String urlDownloadResources = "http://www.essential-craft.hol.es/essential-craft.ressources/"; // facultatif : url de download des resources supplémentaires public final static String WindowName = "Essential-craft"; // "Minecraft Launcher 1.0.8" public final static String profileName = "Essential-craft"; // nom du profil par défaut }
et il me dit sa: Download job ‘Resources’ skipped as there are no files to download
Merci -
http://www.essential-craft.hol.es/essential-craft.ressources/ -> page introuvable
Le bon lien c’est http://essential-craft.hol.es/essential-craft.Resources/ -
Oui je viens de changer le lien mais sa ne change rien …
Codes:
package custom; public class Custom { public final static String urlNews = "http://essential-craft.com"; // "http://mcupdate.tumblr.com" public final static String urlDownload = "http://www.essential-craft.hol.es/essential-craft.download/"; // url de download des versions public final static String urlDownloadResources = "http://www.essential-craft.hol.es/essential-craft.Resources/"; // facultatif : url de download des resources supplémentaires public final static String WindowName = "Essential-craft"; // "Minecraft Launcher 1.0.8" public final static String profileName = "Essential-craft"; // nom du profil par défaut }
Je comprend pas, il devrait tout prendre comme pour le .download …
-
Dans ce cas je vois pas d’où vient le problème, j’ai encore jamais codé avec le nouveau launcher, donc je ne peux pas d’aider plus.
-
J’ai trouvé une autre erreur plus haut:
Delta time to compare resources: 125 ms Couldn't download resources org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 55; Des espaces sont obligatoires entre les ID publicId et systemId. at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(Unknown Source) at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Unknown Source) at javax.xml.parsers.DocumentBuilder.parse(Unknown Source) at net.minecraft.launcher.updater.VersionManager.getModFiles(VersionManager.java:299) at net.minecraft.launcher.updater.VersionManager.downloadResources(VersionManager.java:239) at net.minecraft.launcher.Launcher$1.run(Launcher.java:154) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source)
Et voisi tout mon versionManager.java:
package net.minecraft.launcher.updater; import java.io.File; import java.io.IOException; import java.net.Proxy; import java.net.URL; import java.util.ArrayList; import java.util.Collections; import java.util.EnumMap; import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Set; import java.util.concurrent.ThreadPoolExecutor; import javax.swing.SwingUtilities; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import net.minecraft.launcher.Launcher; import net.minecraft.launcher.OperatingSystem; import net.minecraft.launcher.events.RefreshedVersionsListener; import net.minecraft.launcher.updater.download.DownloadJob; import net.minecraft.launcher.updater.download.Downloadable; import net.minecraft.launcher.versions.CompleteVersion; import net.minecraft.launcher.versions.ReleaseType; import net.minecraft.launcher.versions.Version; import org.w3c.dom.Document; import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; import custom.Custom; public class VersionManager { private final VersionList localVersionList; private final VersionList remoteVersionList; private final ThreadPoolExecutor executorService = new ExceptionalThreadPoolExecutor(8); private final List <refreshedversionslistener>refreshedVersionsListeners = Collections.synchronizedList(new ArrayList<refreshedversionslistener>()); private final Object refreshLock = new Object(); private boolean isRefreshing; public VersionManager(VersionList localVersionList, VersionList remoteVersionList) { this.localVersionList = localVersionList; this.remoteVersionList = remoteVersionList; } public void refreshVersions() throws IOException { synchronized (this.refreshLock) { this.isRefreshing = true; } try { this.localVersionList.refreshVersions(); this.remoteVersionList.refreshVersions(); } catch (IOException ex) { synchronized (this.refreshLock) { this.isRefreshing = false; } throw ex; } if ((this.localVersionList instanceof LocalVersionList)) { for (Version version : this.remoteVersionList.getVersions()) { String id = version.getId(); if (this.localVersionList.getVersion(id) != null) { this.localVersionList.removeVersion(id); this.localVersionList.addVersion(this.remoteVersionList.getCompleteVersion(id)); try { ((LocalVersionList)this.localVersionList).saveVersion(this.localVersionList.getCompleteVersion(id)); } catch (IOException ex) { synchronized (this.refreshLock) { this.isRefreshing = false; } throw ex; } } } } synchronized (this.refreshLock) { this.isRefreshing = false; } final List <refreshedversionslistener>listeners = new ArrayList<refreshedversionslistener>(this.refreshedVersionsListeners); for (Iterator <refreshedversionslistener>iterator = listeners.iterator(); iterator.hasNext(); ) { RefreshedVersionsListener listener = (RefreshedVersionsListener)iterator.next(); if (!listener.shouldReceiveEventsInUIThread()) { listener.onVersionsRefreshed(this); iterator.remove(); } } if (!listeners.isEmpty()) SwingUtilities.invokeLater(new Runnable() { public void run() { for (RefreshedVersionsListener listener : listeners) listener.onVersionsRefreshed(VersionManager.this); } }); } public List <versionsyncinfo>getVersions() { return getVersions(null); } public List <versionsyncinfo>getVersions(VersionFilter filter) { synchronized (this.refreshLock) { if (this.isRefreshing) return new ArrayList<versionsyncinfo>(); } List <versionsyncinfo>result = new ArrayList<versionsyncinfo>(); Map <string, versionsyncinfo="">lookup = new HashMap<string, versionsyncinfo="">(); Map <releasetype, integer="">counts = new EnumMap<releasetype, integer="">(ReleaseType.class); for (ReleaseType type : ReleaseType.values()) { counts.put(type, Integer.valueOf(0)); } for (Version version : this.localVersionList.getVersions()) { if ((version.getType() != null) && (version.getUpdatedTime() != null)) { VersionSyncInfo syncInfo = getVersionSyncInfo(version, this.remoteVersionList.getVersion(version.getId())); lookup.put(version.getId(), syncInfo); result.add(syncInfo); } } for (Version version : this.remoteVersionList.getVersions()) { if ((version.getType() != null) && (version.getUpdatedTime() != null) && (!lookup.containsKey(version.getId())) && ((filter == null) || ((filter.getTypes().contains(version.getType())) && (((Integer)counts.get(version.getType())).intValue() < filter.getMaxCount())))) { VersionSyncInfo syncInfo = getVersionSyncInfo(this.localVersionList.getVersion(version.getId()), version); lookup.put(version.getId(), syncInfo); result.add(syncInfo); if (filter != null) counts.put(version.getType(), Integer.valueOf(((Integer)counts.get(version.getType())).intValue() + 1)); } } return result; } public VersionSyncInfo getVersionSyncInfo(Version version) { return getVersionSyncInfo(version.getId()); } public VersionSyncInfo getVersionSyncInfo(String name) { return getVersionSyncInfo(this.localVersionList.getVersion(name), this.remoteVersionList.getVersion(name)); } public VersionSyncInfo getVersionSyncInfo(Version localVersion, Version remoteVersion) { boolean installed = localVersion != null; boolean upToDate = installed; if ((installed) && (remoteVersion != null)) { upToDate = !remoteVersion.getUpdatedTime().after(localVersion.getUpdatedTime()); } if ((localVersion instanceof CompleteVersion)) { upToDate &= this.localVersionList.hasAllFiles((CompleteVersion)localVersion, OperatingSystem.getCurrentPlatform()); } return new VersionSyncInfo(localVersion, remoteVersion, installed, upToDate); } public List <versionsyncinfo>getInstalledVersions() { List <versionsyncinfo>result = new ArrayList<versionsyncinfo>(); for (Version version : this.localVersionList.getVersions()) { if ((version.getType() == null) || (version.getUpdatedTime() == null)) continue; VersionSyncInfo syncInfo = getVersionSyncInfo(version, this.remoteVersionList.getVersion(version.getId())); result.add(syncInfo); } return result; } public VersionList getRemoteVersionList() { return this.remoteVersionList; } public VersionList getLocalVersionList() { return this.localVersionList; } public CompleteVersion getLatestCompleteVersion(VersionSyncInfo syncInfo) throws IOException { if (syncInfo.getLatestSource() == VersionSyncInfo.VersionSource.REMOTE) { CompleteVersion result = null; IOException exception = null; try { result = this.remoteVersionList.getCompleteVersion(syncInfo.getLatestVersion()); } catch (IOException e) { exception = e; try { result = this.localVersionList.getCompleteVersion(syncInfo.getLatestVersion()); } catch (IOException localIOException1) { } } if (result != null) { return result; } throw exception; } return this.localVersionList.getCompleteVersion(syncInfo.getLatestVersion()); } public DownloadJob downloadVersion(VersionSyncInfo syncInfo, DownloadJob job) throws IOException { if (!(this.localVersionList instanceof LocalVersionList)) throw new IllegalArgumentException("Cannot download if local repo isn't a LocalVersionList"); if (!(this.remoteVersionList instanceof RemoteVersionList)) throw new IllegalArgumentException("Cannot download if local repo isn't a RemoteVersionList"); CompleteVersion version = getLatestCompleteVersion(syncInfo); File baseDirectory = ((LocalVersionList)this.localVersionList).getBaseDirectory(); Proxy proxy = ((RemoteVersionList)this.remoteVersionList).getProxy(); job.addDownloadables(version.getRequiredDownloadables(OperatingSystem.getCurrentPlatform(), proxy, baseDirectory, false)); String jarFile = "versions/" + version.getId() + "/" + version.getId() + ".jar"; String jarFileUri = jarFile.replaceAll(" ", "%20"); job.addDownloadables(new Downloadable[] { new Downloadable(proxy, new URL(Custom.urlDownload + jarFileUri), new File(baseDirectory, jarFile), false) }); return job; } public DownloadJob downloadResources(DownloadJob job) throws IOException { File baseDirectory = ((LocalVersionList)this.localVersionList).getBaseDirectory(); job.addDownloadables(getResourceFiles(((RemoteVersionList)this.remoteVersionList).getProxy(), baseDirectory)); job.addDownloadables(getModFiles(((RemoteVersionList)this.remoteVersionList).getProxy(), baseDirectory)); return job; } private Set <downloadable>getResourceFiles(Proxy proxy, File baseDirectory) { Set <downloadable>result = new HashSet<downloadable>(); try { URL resourceUrl = new URL("https://s3.amazonaws.com/Minecraft.Resources/"); DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); Document doc = db.parse(resourceUrl.openStream()); NodeList nodeLst = doc.getElementsByTagName("Contents"); long start = System.nanoTime(); for (int i = 0; i < nodeLst.getLength(); i++) { Node node = nodeLst.item(i); if (node.getNodeType() == 1) { Element element = (Element)node; String key = element.getElementsByTagName("Key").item(0).getChildNodes().item(0).getNodeValue(); String etag = element.getElementsByTagName("ETag") != null ? element.getElementsByTagName("ETag").item(0).getChildNodes().item(0).getNodeValue() : "-"; long size = Long.parseLong(element.getElementsByTagName("Size").item(0).getChildNodes().item(0).getNodeValue()); if (size > 0L) { File file = new File(baseDirectory, "assets/" + key); if (etag.length() > 1) { etag = Downloadable.getEtag(etag); if ((file.isFile()) && (file.length() == size)) { String localMd5 = Downloadable.getMD5(file); if (localMd5.equals(etag)) continue; } } Downloadable downloadable = new Downloadable(proxy, new URL("https://s3.amazonaws.com/Minecraft.Resources/" + key), file, false); downloadable.setExpectedSize(size); result.add(downloadable); } } } long end = System.nanoTime(); long delta = end - start; Launcher.getInstance().println("Delta time to compare resources: " + delta / 1000000L + " ms "); } catch (Exception ex) { Launcher.getInstance().println("Couldn't download resources", ex); } return result; } private Set <downloadable>getModFiles(Proxy proxy, File baseDirectory) { Set <downloadable>result = new HashSet<downloadable>(); try { URL resourceUrl = new URL(Custom.urlDownloadResources); DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); Document doc = db.parse(resourceUrl.openStream()); NodeList nodeLst = doc.getElementsByTagName("Contents"); long start = System.nanoTime(); for (int i = 0; i < nodeLst.getLength(); i++) { Node node = nodeLst.item(i); if (node.getNodeType() == 1) { Element element = (Element)node; String key = element.getElementsByTagName("Key").item(0).getChildNodes().item(0).getNodeValue(); String etag = element.getElementsByTagName("ETag") != null ? element.getElementsByTagName("ETag").item(0).getChildNodes().item(0).getNodeValue() : "-"; long size = Long.parseLong(element.getElementsByTagName("Size").item(0).getChildNodes().item(0).getNodeValue()); if (size > 0L) { File file = new File(baseDirectory, "/" + key); if (etag.length() > 1) { etag = Downloadable.getEtag(etag); if ((file.isFile()) && (file.length() == size)) { String localMd5 = Downloadable.getMD5(file); if (localMd5.equals(etag)) continue; } } Downloadable downloadable = new Downloadable(proxy, new URL(Custom.urlDownloadResources + key), file, false); downloadable.setExpectedSize(size); result.add(downloadable); } } } long end = System.nanoTime(); long delta = end - start; Launcher.getInstance().println("Delta time to compare resources: " + delta / 1000000L + " ms "); } catch (Exception ex) { Launcher.getInstance().println("Couldn't download resources", ex); } return result; } public ThreadPoolExecutor getExecutorService() { return this.executorService; } public void addRefreshedVersionsListener(RefreshedVersionsListener listener) { this.refreshedVersionsListeners.add(listener); } public void removeRefreshedVersionsListener(RefreshedVersionsListener listener) { this.refreshedVersionsListeners.remove(listener); } } ```</downloadable></downloadable></downloadable></downloadable></downloadable></downloadable></versionsyncinfo></versionsyncinfo></versionsyncinfo></releasetype,></releasetype,></string,></string,></versionsyncinfo></versionsyncinfo></versionsyncinfo></versionsyncinfo></versionsyncinfo></refreshedversionslistener></refreshedversionslistener></refreshedversionslistener></refreshedversionslistener></refreshedversionslistener>
-
org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 55; Des espaces sont obligatoires entre les ID publicId et systemId.
Le launcher n’arrive pas à lire le fichier xml. Je n’ai pas encore codé avec le nouveau launcher, mais à voir l’erreur et les serveurs de mojang, le launcher se base sur des fichiers xml pour obtenir les liens
(cf : https://s3.amazonaws.com/Minecraft.Download/, sauf que la ça fait un accès deny, au pire google -> fichier xml).