[Question] IC2 1.97 in NetBeans/MCP Testing Environment

  • I've recently been trying to create a new mod for my server and I've hit an annoyance when trying to add in some IC2 functionality due to the fact that I haven't been able to add a full copy of IC2 to my testing environment (from inside NetBeans, hitting the run option). I tried loading my mod with just the API, but that only ends up throwing RuntimeExceptions when the IC2 API tries to call stuff in ic2.platform, which isn't present, and, even if that wasn't the case, I realized it would be somewhat futile to try and test a machine that requires power without having access to any of the actual blocks that produce it. Afte that, without thinking much about it, I tried just dumping the IC2 jar into the mods folder of the test version of the application, but that doesn't work since the code is compiled, but still unobfuscated at the time. After reading through the forums a lot, I've already gathered that decompiling it isn't an option. :pinch:


    I'd really like to be able to test things through NetBeans, rather than going through the added steps of reobfuscating the code, copying it into a full version of Minecraft, and running things there, so, my question is: is there any easy way to get a full copy of IC2 working through the IDE? I realize that later on, I'll be primarily testing it with a client/server pair, so, it isn't a major issue, but, it would help me in tracking down bugs early on.


    Thank you.

  • If you add IC2 as a library, it causes the same effect as if you were to load it into the mods folder of the test environment - NoClassDefFoundError due to the code not being reobfuscated at that point. I'm assuming, given that, I will just end up having to reobfuscate and run it in my full Minecraft install every time I want to test a block that uses IC2.


  • You know, the only use of API's is exactly to DEFEAT the requirement of having the decompiled core files...

    I agree with that, hence why I expressly mentioned that I had no intentions of even trying to do so in the OP. :)


    I'm mostly wondering if there's a way to save time - hitting "Build" then "Run" is a lot easier than running a recompile, reobfuscate, copying the plugin over to my full version of Minecraft, waiting for the launcher to load, waiting for the game to load... all just to check if the one liner I just changed makes that pesky NPE go away. Not to mention having direct console output in NetBeans rather than digging through a log file. (I'll admit half of this is a problem only because I'm really lazy and using Tekkit instead of installing the mods myself... :whistling:)


    That said, it's still not a huge deal to me, especially because the only way I can see it working is if a version of IC2 was released that referenced all the unobfuscated base classes instead of the obfuscated ones... and that just seems like way too much work. 8)