Posted May 8, 201312 yr I've wrote small mod which introduces new block (fuel generator). This block use some functionality form BuildCraft and IC2. It's very simple mod: just three files (core, block, tile) To compile it I put code into installed forge with sources: forge/mcp/src/minecraft So, this folder now contains minecraft sources and my_mod package with mod's classes. Then I copy latest binaries (jars) of BuildCraft & IC2 into forge/mcp/lib. (jar with IC2 I got from http://ic2api.player.to:8080/. It successfully works on 1.5.1 mc) Then I run recompile.bat: == MCP 7.44 (data: 7.44, client: 1.5.1, server: 1.5.1) == "scala" does not support jvm-1.6 target, it is out of date. Ignoring # found ff, ff patches, srgs, name csvs, doc csvs, param csvs, renumber csv, ast yle, astyle config == Recompiling client == > Cleaning bin > Recompiling - Done in 10.53 seconds !! Can not find server sources, try decompiling !! Now, I can found compiled classes in forge/mcp/bin/minecraft Then I run reobfuscate.bat: == MCP 7.44 (data: 7.44, client: 1.5.1, server: 1.5.1) == "scala" does not support jvm-1.6 target, it is out of date. Ignoring # found ff, ff patches, srgs, name csvs, doc csvs, param csvs, renumber csv, ast yle, astyle config > Creating Retroguard config files == Reobfuscating client == > Cleaning reobf > Generating md5s > Packing jar > Reobfuscating jar '"C:\Program Files\Java\jdk1.7.0_13\bin\java" -cp "runtime\bin\retroguard.jar;lib;lib\*;jars\bin\mine...' failed : 1 == ERRORS FOUND == Exception in thread "main" java.lang.NoClassDefFoundError: net/minecraft/world/World at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2451) at java.lang.Class.privateGetPublicMethods(Class.java:2571) at java.lang.Class.getMethods(Class.java:1429) at COM.rl.obf.Cl$ExtNameListUp.getAllDeclaredMethods(Cl.java:1674) at COM.rl.obf.Cl$ExtNameListUp.getMethodOutNameUp(Cl.java:1565) at COM.rl.obf.Cl.resolveThis(Cl.java:980) at COM.rl.obf.Cl.resolveNameSpaceExcept(Cl.java:852) at COM.rl.obf.Cl.resolveOptimally(Cl.java:645) at COM.rl.obf.ClassTree$6.classAction(ClassTree.java:682) at COM.rl.obf.ClassTree.walkTree(ClassTree.java:1483) at COM.rl.obf.ClassTree.walkTree(ClassTree.java:1475) at COM.rl.obf.ClassTree.walkTree(ClassTree.java:1475) at COM.rl.obf.ClassTree.walkTree(ClassTree.java:1466) at COM.rl.obf.ClassTree.walkTree(ClassTree.java:1466) at COM.rl.obf.ClassTree.walkTree(ClassTree.java:1466) at COM.rl.obf.ClassTree.walkTree(ClassTree.java:1447) at COM.rl.obf.ClassTree.resolveClasses(ClassTree.java:677) at COM.rl.obf.GuardDB.createMap(GuardDB.java:437) at COM.rl.obf.GuardDB.remapTo(GuardDB.java:464) at COM.rl.obf.RetroGuardImpl.run(RetroGuardImpl.java:182) at COM.rl.obf.RetroGuardImpl.obfuscate(RetroGuardImpl.java:131) at COM.rl.obf.RetroGuardImpl.obfuscate(RetroGuardImpl.java:113) at RetroGuard.main(RetroGuard.java:90) Caused by: java.lang.ClassNotFoundException: net.minecraft.world.World at java.net.URLClassLoader$1.run(URLClassLoader.java:366) at java.net.URLClassLoader$1.run(URLClassLoader.java:355) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:354) at java.lang.ClassLoader.loadClass(ClassLoader.java:423) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308) at java.lang.ClassLoader.loadClass(ClassLoader.java:356) ... 24 more ================== FATAL ERROR Traceback (most recent call last): File "runtime\reobfuscate.py", line 56, in reobfuscate reobfuscate_side(commands, CLIENT, reobf_all=reobf_all, srg_names=srg_names) File "D:\projects\forge\mcp\runtime\mcp.py", line 158, in reobfuscate_side commands.applyrg(side, True) File "D:\projects\forge\mcp\runtime\commands.py", line 948, in applyrg self.runcmd(forkcmd) File "D:\projects\forge\mcp\runtime\commands.py", line 1173, in runcmd raise CalledProcessError(process.returncode, forkcmd, output) CalledProcessError: Command '"C:\Program Files\Java\jdk1.7.0_13\bin\java" -cp "runtime\bin\retroguard.jar;lib;lib\*;jars\bin\minecraft.jar;jars\bin\jinput.jar;jars\bin\lwjgl.jar;jars\bin\lwjgl_util.jar" RetroGuard -notch temp\client_ro.cfg' returned non-zero exit status 1 My environment: 1. windows 7 2. java 7_13 (I tried latest java 6, but it did not help) Please, help me. I really do not have any ideas what is wrong. I tried to find the class manually in forge/mcp/bin/minecraft directory; in forge/temp/client_recomp.jar - it exists. Thanks.
May 9, 201312 yr Author Does anybody have idea? Maybe I put mod code to wrong folder? Or could somebody provide link to mod example sources?
May 9, 201312 yr I'm having the exact same problem. I think it's an MCP glitch, the next version may fix the problem.
May 10, 201312 yr I'm having the exact same problem. I think it's an MCP glitch, the next version may fix the problem. No it's not: "scala" does not support jvm-1.6 target, it is out of date. Ignoring I had the problem on my linux machine, too. Update scala and you should be fine. Don't ask for support per PM! They'll get ignored! | If a post helped you, click the "Thank You" button at the top right corner of said post! | mah twitter This thread makes me sad because people just post copy-paste-ready code when it's obvious that the OP has little to no programming experience. This is not how learning works.
May 10, 201312 yr Author MultipleMonomials and SanAndreasP thanks for your replays! I try to update scala version (but on windows). Now it is v 2.10.1. But I had the same error. I looked through commands.py and found the reason of the problem in checkscala method: self.runcmd('scala -target:jvm-1.6 -version', quiet=False) causes error 2, it means that file doesn't exists. I fix it for windows only: self.runcmd('scala.bat -target:jvm-1.6 -version', quiet=False) but then it returned non zero return code (I really don't' know why), and output was: Scala code runner version 2.10.1 -- Copyright 2002-2013, LAMP/EPFL I'm not so experienced in Python, and it's very difficult to understand what the right flow should be. Could someone provide any explanation of what this method should do and what right output should be?
May 10, 201312 yr Author I tried to rewrite checkscala method, and remove all checks (I know that my scala version is right 2.10.1). And just pass the line where it sets cmdscala variable: def checkscala(self): results = [] if not results: try: # TODO: Verify at least version 2.10 self.runcmd('scalac.bat -version', quiet=True) results.append('') except (CalledProcessError, OSError): pass if not results: self.logger.warning('"scalac" is not found on the PATH. Scala files will not be recompiled') self.cmdscalac = None else: self.cmdscalac = '"%s"' % os.path.join(results[0], 'scalac.bat') (of course it work only for windows with right path var in environment) But, when I run recompile (it works in second times longer then without scala) and then reobfuscate I got exactly the same error.
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.