ChromaKey81 Posted June 26, 2020 Posted June 26, 2020 (edited) Novice modder here. I can't figure out how to get my mods.toml to work; when I run client it fails to build. Latest log: [26Jun2020 12:25:19.671] [main/INFO] [cpw.mods.modlauncher.Launcher/MODLAUNCHER]: ModLauncher running: args [--gameDir, ., --launchTarget, fmluserdevclient, --fml.mcpVersion, 20200515.085601, --fml.mcVersion, 1.15.2, --fml.forgeGroup, net.minecraftforge, --fml.forgeVersion, 31.2.0, --version, MOD_DEV, --assetIndex, 1.15, --assetsDir, C:\Users\willi\.gradle\caches\forge_gradle\assets, --username, Dev, --accessToken, ????????, --userProperties, {}] [26Jun2020 12:25:19.683] [main/INFO] [cpw.mods.modlauncher.Launcher/MODLAUNCHER]: ModLauncher 5.1.0+69+master.79f13f7 starting: java version 14.0.1 by AdoptOpenJDK [26Jun2020 12:25:20.423] [main/INFO] [net.minecraftforge.fml.loading.FixSSL/CORE]: Added Lets Encrypt root certificates as additional trust [26Jun2020 12:25:22.391] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: java.lang.RuntimeException: java.net.MalformedURLException: no protocol: minecraftforge.net/versions.json [26Jun2020 12:25:22.392] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.StringUtils.toURL(StringUtils.java:51) [26Jun2020 12:25:22.394] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.Optional.map(Optional.java:258) [26Jun2020 12:25:22.394] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.moddiscovery.ModInfo.<init>(ModInfo.java:90) [26Jun2020 12:25:22.396] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.moddiscovery.ModFileInfo.lambda$new$2(ModFileInfo.java:70) [26Jun2020 12:25:22.398] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195) [26Jun2020 12:25:22.399] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1624) [26Jun2020 12:25:22.400] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484) [26Jun2020 12:25:22.400] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474) [26Jun2020 12:25:22.401] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913) [26Jun2020 12:25:22.402] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) [26Jun2020 12:25:22.403] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578) [26Jun2020 12:25:22.403] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.moddiscovery.ModFileInfo.<init>(ModFileInfo.java:70) [26Jun2020 12:25:22.404] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.moddiscovery.ModFileParser.loadModFile(ModFileParser.java:59) [26Jun2020 12:25:22.405] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.moddiscovery.ModFileParser.readModList(ModFileParser.java:51) [26Jun2020 12:25:22.405] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.moddiscovery.ModFile.identifyMods(ModFile.java:132) [26Jun2020 12:25:22.406] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.moddiscovery.ModDiscoverer.discoverMods(ModDiscoverer.java:116) [26Jun2020 12:25:22.407] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.FMLLoader.beginModScan(FMLLoader.java:211) [26Jun2020 12:25:22.408] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.fml.loading.FMLServiceProvider.runScan(FMLServiceProvider.java:105) [26Jun2020 12:25:22.408] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at cpw.mods.modlauncher.TransformationServiceDecorator.runScan(TransformationServiceDecorator.java:111) [26Jun2020 12:25:22.409] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at cpw.mods.modlauncher.TransformationServicesHandler.lambda$runScanningTransformationServices$8(TransformationServicesHandler.java:115) [26Jun2020 12:25:22.411] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.ReferencePipeline$7$1.accept(ReferencePipeline.java:271) [26Jun2020 12:25:22.412] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.HashMap$ValueSpliterator.forEachRemaining(HashMap.java:1766) [26Jun2020 12:25:22.413] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484) [26Jun2020 12:25:22.414] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474) [26Jun2020 12:25:22.415] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913) [26Jun2020 12:25:22.415] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) [26Jun2020 12:25:22.416] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578) [26Jun2020 12:25:22.416] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at cpw.mods.modlauncher.TransformationServicesHandler.runScanningTransformationServices(TransformationServicesHandler.java:116) [26Jun2020 12:25:22.418] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at cpw.mods.modlauncher.TransformationServicesHandler.initializeTransformationServices(TransformationServicesHandler.java:63) [26Jun2020 12:25:22.418] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at cpw.mods.modlauncher.Launcher.run(Launcher.java:75) [26Jun2020 12:25:22.419] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [26Jun2020 12:25:22.419] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1048]: at net.minecraftforge.userdev.LaunchTesting.main(LaunchTesting.java:102) [26Jun2020 12:25:22.420] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1057]: Caused by: java.net.MalformedURLException: no protocol: minecraftforge.net/versions.json [26Jun2020 12:25:22.420] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1057]: at java.base/java.net.URL.<init>(URL.java:672) [26Jun2020 12:25:22.421] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1057]: at java.base/java.net.URL.<init>(URL.java:568) [26Jun2020 12:25:22.421] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1057]: at java.base/java.net.URL.<init>(URL.java:515) [26Jun2020 12:25:22.422] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1057]: at net.minecraftforge.fml.loading.StringUtils.toURL(StringUtils.java:47) [26Jun2020 12:25:22.423] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1057]: ... 31 more Here's my mods.toml file: # This is an example mods.toml file. It contains the data relating to the loading mods. # There are several mandatory fields (#mandatory), and many more that are optional (#optional). # The overall format is standard TOML format, v0.5.0. # Note that there are a couple of TOML lists in this file. # Find more information on toml format here: https://github.com/toml-lang/toml # The name of the mod loader type to load - for regular FML @Mod mods it should be javafml modLoader="javafml" #mandatory # A version range to match for said mod loader - for regular FML @Mod it will be the forge version loaderVersion="[31,)" #mandatory This is typically bumped every Minecraft version by Forge. See our download page for lists of versions. # A URL to refer people to when problems occur with this mod issueTrackerURL="http://my.issue.tracker/" #optional # A list of mods - how many allowed here is determined by the individual mod loader [[mods]] #mandatory # The modid of the mod modId="devsdream" #mandatory # The version number of the mod - there's a few well known ${} variables useable here or just hardcode it version="${file.jarVersion}" #mandatory # A display name for the mod displayName="Developer's Dream" #mandatory # A URL to query for updates for this mod. See the JSON update specification <here> updateJSONURL="http://myurl.me/" #optional # A URL for the "homepage" for this mod, displayed in the mod UI displayURL="http://example.com/" #optional # A file name (in the root of the mod JAR) containing a logo for display logoFile="examplemod.png" #optional # A text field displayed in the mod UI credits="Thanks for this example mod goes to Java" #optional # A text field displayed in the mod UI authors="Love, Cheese and small house plants" #optional # The description text for the mod (multi line!) (#mandatory) description=''' This is a long form description of the mod. You can write whatever you want here Have some lorem ipsum. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed mollis lacinia magna. Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Sed sagittis luctus odio eu tempus. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque volutpat ligula eget lacus auctor sagittis. In hac habitasse platea dictumst. Nunc gravida elit vitae sem vehicula efficitur. Donec mattis ipsum et arcu lobortis, eleifend sagittis sem rutrum. Cras pharetra quam eget posuere fermentum. Sed id tincidunt justo. Lorem ipsum dolor sit amet, consectetur adipiscing elit. ''' # A dependency - use the . to indicate dependency for a specific modid. Dependencies are optional. [[dependencies.devsdream]] #optional # the modid of the dependency modId="forge" #mandatory # Does this dependency have to exist - if not, ordering below must be specified mandatory=true #mandatory # The version range of the dependency versionRange="[31,)" #mandatory # An ordering relationship for the dependency - BEFORE or AFTER required if the relationship is not mandatory ordering="NONE" # Side this dependency is applied on - BOTH, CLIENT or SERVER side="BOTH" # Here's another dependency [[dependencies.devsdream]] modId="minecraft" mandatory=true versionRange="[1.15.2]" ordering="NONE" side="BOTH" My mod id is "devsdream" Edited June 26, 2020 by ChromaKey81 updated code Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 (edited) Figured it out, I think I was using an outdated template Still have not figured it out Edited June 26, 2020 by ChromaKey81 Quote
sciwhiz12 Posted June 26, 2020 Posted June 26, 2020 Remove the following: updateJSONURL="minecraftforge.net/versions.json" displayURL="minecraftforge.net" I recommend removing any property which you will not use. (logoFile, *URL) BTW, might I suggest lengthen your modid from 'devd'? Try 'devsdream', or whatever you please. Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 2 minutes ago, sciwhiz12 said: Remove the following: updateJSONURL="minecraftforge.net/versions.json" displayURL="minecraftforge.net" I recommend removing any property which you will not use. (logoFile, *URL) BTW, might I suggest lengthen your modid from 'devd'? Try 'devsdream', or whatever you please. Done, but I'm still getting the same errors. The log still says minecraftforge.net/versions.json despite that URL never being used in the file, so I have no idea what's happening. Quote
sciwhiz12 Posted June 26, 2020 Posted June 26, 2020 Hmm, that should have fixed it, unless another mods.toml still exists with that line. Could you upload your code as a Git repo? Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 6 minutes ago, sciwhiz12 said: Hmm, that should have fixed it, unless another mods.toml still exists with that line. Could you upload your code as a Git repo? https://github.com/ChromaKey81/devsdream Quote
sciwhiz12 Posted June 26, 2020 Posted June 26, 2020 I can't see anything out of place with your mods.toml, which leads me to believe that your run dirs, somewhere, has another mods.toml. Please download a fresh copy of the Forge MDK, configure it until it runs to the client and the example mod is loaded. Then, delete everything from the example mod's src and resources, copy over your src & resources. Then try running. If that doesn't work, please post the folder containing your build.gradle and mod code. I am mystified as how this is occuring (unless you are running the wrong run configuration) Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 25 minutes ago, sciwhiz12 said: I can't see anything out of place with your mods.toml, which leads me to believe that your run dirs, somewhere, has another mods.toml. Please download a fresh copy of the Forge MDK, configure it until it runs to the client and the example mod is loaded. Then, delete everything from the example mod's src and resources, copy over your src & resources. Then try running. If that doesn't work, please post the folder containing your build.gradle and mod code. I am mystified as how this is occuring (unless you are running the wrong run configuration) I updated my stuff with fresh files, and now I have a new error: java.lang.RuntimeException: java.net.MalformedURLException: no protocol: github.com/MinecraftForge/MinecraftForge/issues I'm still confused because I deleted this line in the mods.toml. I uploaded everything to the github repo so there's more info available. Quote
sciwhiz12 Posted June 26, 2020 Posted June 26, 2020 Aha! Remove the file 'modid-1.0.jar' from the 'run/mods' folder. If you placed it there, remember that you are running the dev client; any code in src/main should automagically be found. Also, please change the defaults in your build.gradle. Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 (edited) 8 minutes ago, sciwhiz12 said: Aha! Remove the file 'modid-1.0.jar' from the 'run/mods' folder. If you placed it there, remember that you are running the dev client; any code in src/main should automagically be found. Also, please change the defaults in your build.gradle. Thank you very much for the help (although now my game is crashing altogether. check repo for crash report) Could you briefly explain what I need to change in the build.gradle (or direct me to some documentation)? By the way, do I need to compile all of my .java files to .class? How would I do that in VSCode? Edited June 26, 2020 by ChromaKey81 Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 (edited) how do i delete replies lol Edited June 26, 2020 by ChromaKey81 tried to delete Quote
Curle Posted June 26, 2020 Posted June 26, 2020 It doesn't seem possible for a user to delete posts. However, getting VSCode to work properly with Java, especially compiling and debugging, is a pain in the proverbial for most people, so i reccommend you stick to one of IntelliJ or Eclipse until you get the hang of it. Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 (edited) 4 minutes ago, Curle said: It doesn't seem possible for a user to delete posts. However, getting VSCode to work properly with Java, especially compiling and debugging, is a pain in the proverbial for most people, so i reccommend you stick to one of IntelliJ or Eclipse until you get the hang of it. I just need the forge library and I'll be set. Where can I download that? Nvm I found it Edited June 26, 2020 by ChromaKey81 Quote
sciwhiz12 Posted June 26, 2020 Posted June 26, 2020 The most recent crash report is a recurring issue in Forge currently. (revelant issue) Try running it again. 10 minutes ago, ChromaKey81 said: Could you briefly explain what I need to change in the build.gradle (or direct me to some documentation)? The 'archiveBaseName', 'group', and replacing 'examplemod' and 'examplemodareus' with respective modid and your author name. 12 minutes ago, ChromaKey81 said: By the way, do I need to compile all of my .java files to .class? How would I do that in VSCode? I am not familliar with java coding with VSCode. Although VSCode has an associated task built for it (genVSCodeRuns), as said above, you are better off using IntelliJ IDEA or Eclipse. (unless you wish to stick to VSCode, in which case I wish you good luck and fun) Quote
Curle Posted June 26, 2020 Posted June 26, 2020 The "Forge Library" is generated by one of the IDEs during the gradle setup and first sync. If you can't find it from there, you probably shouldn't be using VSCode. Quote
ChromaKey81 Posted June 26, 2020 Author Posted June 26, 2020 10 minutes ago, Curle said: The "Forge Library" is generated by one of the IDEs during the gradle setup and first sync. If you can't find it from there, you probably shouldn't be using VSCode. I can't find it from there in IntelliJ IDEA either. Do you know what the usual directory is? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.