Skip to content
This repository has been archived by the owner on May 13, 2021. It is now read-only.

Performing the update check earlier in the mod-loading process? #10

Open
aetherknight opened this issue Sep 11, 2016 · 9 comments
Open

Comments

@aetherknight
Copy link

Is it feasible to have the update check run before Forge spends all that time initializing mods?

For any modpack of moderate size, it can easily take a few minutes before LaunchGUI's update checker displays the notification that the modpack has been updated. If it were to display during an earlier phase of mods loading, it could save users a few minutes of time before finding out that they will have update their pack and restart Minecraft.

I'm guessing that LaunchGUI currently uses the GUI facilities provided by Minecraft, which might not be available for use before all the mods are loaded (and the textures are reloaded).

@TehNut
Copy link
Member

TehNut commented Sep 11, 2016

I do not think I can display the GUI any earlier than I already do.

I can open a new Window and display more or less the same GUI during startup though. Would that work?

@TehNut
Copy link
Member

TehNut commented Sep 12, 2016

@aetherknight
Copy link
Author

aetherknight commented Sep 12, 2016

That would definitely work. Thanks for the quick PoC/stream!

@TehNut
Copy link
Member

TehNut commented Sep 12, 2016

Here is how it currently looks

The "LaunchGui" in the title is replaced with whatever modpackName is set to in the config. The button names use the configs continueButtonText and updateInformationButtonText. The button that says "Changelog" opesn the URL set for updateInformationUrl.

@TehNut
Copy link
Member

TehNut commented Sep 12, 2016

Just pushed an Alpha to Curse. Could you try it out and let me know if everything works seamlessly? It should enable by default.

@aetherknight
Copy link
Author

Tried build 2.0.3-22, but it is crashing with an exception:

https://gist.github.com/aetherknight/0d176a70c3372cf19f47fb03c7b11090

Hmm, that error seems odd to me b/c it seems to be due to a javafx class not being included in my Java runtime (although I've never used javafx much). I am using JRE 1.8.0_74, which is what the Minecraft launcher has bundled with it on Mac OS X.

@TehNut
Copy link
Member

TehNut commented Sep 15, 2016

...does Mojang not ship the JavaFX runtime in their JRE?

E: Actually, I'm getting this in my standard Oracle JRE.

@aetherknight
Copy link
Author

aetherknight commented Sep 15, 2016

I think the problem may be related to loading the javafx runtime, which requires some special setup. Based on:

http://stackoverflow.com/questions/16868446/javafx-exception-in-thread-main-java-lang-noclassdeffounderror-javafx-applica

It sounds to me like the jfxrt.jar file (which is included with the JRE) is not included in the Java classpath by default. I checked the file manifest for jfxrtj.jar, and it contains java/application/Application.class, as well as a lot of other classes.

@TehNut
Copy link
Member

TehNut commented Sep 15, 2016

Well, I've tried, but I have no clue how to fix this without having users add it to the classpath themselves. I even went as far as using JCL to try to load the jar in, but still no dice.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants