Jump to content

[1.8][SOLVED] Forge Gradle eclipse, core mods don't load correctly


a9d9d9djgdj

Recommended Posts

Currently in my forge build for 1.8 I have found that every time I try to add a core mod (specifically codechickencore and NEI, though this includes PlayerAPI and RenderPlayerAPI) it will give me the following error.

 

 

java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_11]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_11]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_11]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_11]
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.11.jar:?]
at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.11.jar:?]
at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:78) [start/:?]
at GradleStart.main(GradleStart.java:45) [start/:?]
Caused by: java.lang.NoClassDefFoundError: net/minecraftforge/common/util/FakePlayer
at net.minecraft.item.Item.registerItems(Item.java:1368) ~[item.class:?]
at net.minecraft.init.Bootstrap.register(Bootstrap.java:553) ~[bootstrap.class:?]
at net.minecraft.client.Minecraft.<init>(Minecraft.java:315) ~[Minecraft.class:?]
at net.minecraft.client.main.Main.main(Main.java:117) ~[Main.class:?]
... 8 more
Caused by: java.lang.ClassNotFoundException: net.minecraftforge.common.util.FakePlayer
at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:191) ~[launchwrapper-1.11.jar:?]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at net.minecraft.item.Item.registerItems(Item.java:1368) ~[item.class:?]
at net.minecraft.init.Bootstrap.register(Bootstrap.java:553) ~[bootstrap.class:?]
at net.minecraft.client.Minecraft.<init>(Minecraft.java:315) ~[Minecraft.class:?]
at net.minecraft.client.main.Main.main(Main.java:117) ~[Main.class:?]
... 8 more
Caused by: java.lang.NoClassDefFoundError: net/minecraft/entity/player/EntityPlayerMP
at java.lang.ClassLoader.defineClass1(Native Method) ~[?:1.8.0_11]
at java.lang.ClassLoader.defineClass(Unknown Source) ~[?:1.8.0_11]
at java.security.SecureClassLoader.defineClass(Unknown Source) ~[?:1.8.0_11]
at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:182) ~[launchwrapper-1.11.jar:?]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at net.minecraft.item.Item.registerItems(Item.java:1368) ~[item.class:?]
at net.minecraft.init.Bootstrap.register(Bootstrap.java:553) ~[bootstrap.class:?]
at net.minecraft.client.Minecraft.<init>(Minecraft.java:315) ~[Minecraft.class:?]
at net.minecraft.client.main.Main.main(Main.java:117) ~[Main.class:?]
... 8 more
Caused by: java.lang.ClassNotFoundException: net.minecraft.entity.player.EntityPlayerMP
at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:101) ~[launchwrapper-1.11.jar:?]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at java.lang.ClassLoader.defineClass1(Native Method) ~[?:1.8.0_11]
at java.lang.ClassLoader.defineClass(Unknown Source) ~[?:1.8.0_11]
at java.security.SecureClassLoader.defineClass(Unknown Source) ~[?:1.8.0_11]
at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:182) ~[launchwrapper-1.11.jar:?]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_11]
at net.minecraft.item.Item.registerItems(Item.java:1368) ~[item.class:?]
at net.minecraft.init.Bootstrap.register(Bootstrap.java:553) ~[bootstrap.class:?]
at net.minecraft.client.Minecraft.<init>(Minecraft.java:315) ~[Minecraft.class:?]
at net.minecraft.client.main.Main.main(Main.java:117) ~[Main.class:?]
... 8 more

(This is the error from PlayerAPI, codechickencore and NEI have longer and harder to read errors, but the concept is the same with both)

 

 

Again, this is for 1.8, I've looked for awhile for an answer and I'm sure it is something obvious, but I'd like a fresh pair of eyes on this. Thank you

Link to comment
Share on other sites

Yes, I can provide links if necessary, but PlayerAPI, RenderPlayerAPI, CodeChickenCore, and NEI are all available for 1.8. Also, as a foot note. I can fix the problem (sort of) by calling Class.forName("CLASS_NAME"); which then loads the class and all is good. However, this doesn't fix the problem, more like a hotfix. Also, possibly unrelated. Minecraftforge mistakes CodeChickenCore for being a duplicate mod as seen here.

 

[13:24:33] [Client thread/ERROR] [FML]: Found a duplicate mod CodeChickenCore at [minecraft.jar, minecraft.jar]

Link to comment
Share on other sites

I currently have the same problem with Nei and code chickencore, it loads them fine if I just put them in the mods folder, however when I add them to he build path for use as libraries it gives that error. www.pastebin.com/JnTwP5pw

 

If you use Class.forName("net.minecraft.client.gui.inventory.GuiInventory"); (as long as your mod is a core mod, maybe it'd work otherwise, I never tried) then it resolves that.

 

Link to comment
Share on other sites

I would agree with you if it didn't work at all but it works when just in mods folder, so why would it not work when in build path aswell. Surely if it was chickenbones it wouldn't work at all. And I'm not making a core mod I'm trying to use codechicken's mods as libraries and they use one. But as I've said I believe it to be a forge problem.

Currently making a voxel game.

Link to comment
Share on other sites

Alright, thanks to you termin8or I think I've found the solution. Inside the eclipse/mods folder delete all the mods inside their. Put them instead inside the jars folder inside the eclipse workspace and then add to build path. It seems to work fine with me now doing that.

Link to comment
Share on other sites

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.