I have created a mod and have set up a proxy using this line:
public static IProxy proxy = new DistExecutor.runForDist(() -> () -> () -> new ClientProxy(), () -> () -> () -> new ServerProxy());
When I have this line uncommented in Eclipse, it red underlines 'DistExecutor.runForDist' and says:
DistExecutor.runForDist cannot be resolved to a type.
However, when I click the run button, Eclipse loads up Minecraft as if there are no errors at all but my mod does not show up. And looking through the logs shows no sign of it even getting to the setup stage of my mod.
When I comment out the line, Eclipse runs Minecraft, but like before my mod does not show up (there are no errors anywhere else).
Because of this, I decided to start up my game using Terminal. When the line is commented out, the mod compiles and shows up in the game. When the line is uncommented, it does not compile. It shows this error in the terminal:
It seems to me that DistExecutor.runForDist is an actual error and not one of the Eclipse 'ghost errors'. Just to make sure I wasn't going crazy, I looked at the source code for forge and indeed, 'runForDist' is a valid function.
What is causing Eclipse to think this is an error?
Thanks,
Dream
https://pastebin.com/zqpT0Rzt - main code
https://pastebin.com/FbcRv6ah - latest.log (debug.log was too large) - this is the log when the mod did compile. There is no log produced when it doesn't compile.