Jump to content

SteamPunk_Devil

Members
  • Posts

    12
  • Joined

  • Last visited

Everything posted by SteamPunk_Devil

  1. now that GameRegistry#findBlock() is deprecated what is the best way to get a block by its modid and name? public static void addStructure(String file) { JSONParser parser = new JSONParser(); try { Object json = parser.parse(new FileReader(file)); JSONObject jsonObject = (JSONObject) json; String name = (String) jsonObject.get("Name"); String village = (String) jsonObject.get("Village"); Map<Integer,Block> legend = new HashMap<Integer,Block>(); JSONArray Legend = (JSONArray) jsonObject.get("Legend"); //Iterator<String> iterator = Legend.iterator(); int i = 1; Legend.forEach( (a)-> { String b; b = a.toString(); String[] bl = b.split(":"); //legend.put(i); String modid = bl[0]; String block = bl[1]; System.out.println(block + modid); Block bk = GameRegistry.findBlock(modid, block); System.out.println(bk); //i =+ 1; }); System.out.println("Loading Structure: " + name); //worldObject newWorldObject = new worldObject(name, village,); }catch (Exception e){ e.printStackTrace(); }
  2. Download https://repo1.maven.org/maven2/io/netty/netty-all/4.0.23.Final/netty-all-4.0.23.Final.jar Download https://repo1.maven.org/maven2/com/google/guava/guava/17.0/guava-17.0.jar Download https://repo1.maven.org/maven2/org/apache/commons/commons-lang3/3.3.2/commons-lang3-3.3.2.jar Download https://repo1.maven.org/maven2/commons-io/commons-io/2.4/commons-io-2.4.jar Download https://repo1.maven.org/maven2/commons-codec/commons-codec/1.9/commons-codec-1.9.jar Download https://repo1.maven.org/maven2/net/java/jutils/jutils/1.0.0/jutils-1.0.0.jar Download https://libraries.minecraft.net/com/mojang/authlib/1.5.24/authlib-1.5.24.jar Download https://libraries.minecraft.net/com/mojang/realms/1.10.4/realms-1.10.4.jar :decompileMc FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':decompileMc'. > Could not resolve all dependencies for configuration ':forgeGradleMcDeps'. > Could not download realms.jar (com.mojang:realms:1.10.4) > Could not get resource 'https://libraries.minecraft.net/com/mojang/realms/1.10.4/realms-1.10.4.jar'. > Failed to move file 'C:\Users\b\AppData\Local\Temp\gradle_download4881369023261230786bin' into filestore at 'C:\Users\b\.gradle\caches\modules-2\files-2.1\com.mojang\realms\1.10.4\7e837a5eae3fc08b13d5e1baf5ddf5b5d31aa2ff\realms-1.10.4.jar' * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED Total time: 7 mins 3.487 secs
  3. Download https://repo1.maven.org/maven2/io/netty/netty-all/4.0.23.Final/netty-all-4.0.23.Final.jar Download https://repo1.maven.org/maven2/com/google/guava/guava/17.0/guava-17.0.jar Download https://repo1.maven.org/maven2/org/apache/commons/commons-lang3/3.3.2/commons-lang3-3.3.2.jar Download https://repo1.maven.org/maven2/commons-io/commons-io/2.4/commons-io-2.4.jar Download https://repo1.maven.org/maven2/commons-codec/commons-codec/1.9/commons-codec-1.9.jar Download https://repo1.maven.org/maven2/net/java/jutils/jutils/1.0.0/jutils-1.0.0.jar Download https://libraries.minecraft.net/com/mojang/authlib/1.5.24/authlib-1.5.24.jar Download https://libraries.minecraft.net/com/mojang/realms/1.10.4/realms-1.10.4.jar :decompileMc FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':decompileMc'. > Could not resolve all dependencies for configuration ':forgeGradleMcDeps'. > Could not download realms.jar (com.mojang:realms:1.10.4) > Could not get resource 'https://libraries.minecraft.net/com/mojang/realms/1.10.4/realms-1.10.4.jar'. > Failed to move file 'C:\Users\b\AppData\Local\Temp\gradle_download4881369023261230786bin' into filestore at 'C:\Users\b\.gradle\caches\modules-2\files-2.1\com.mojang\realms\1.10.4\7e837a5eae3fc08b13d5e1baf5ddf5b5d31aa2ff\realms-1.10.4.jar' * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED Total time: 7 mins 3.487 secs
  4. Ive been working on my new mod but am having issues getting it to spawn in the world. It can grow from a sapling. Code: https://github.com/Bertieio/SpiceItUp
  5. i was wondering how I would make it so a tool would have an enchant on crafting?
  6. Extra Tools 1.0 This is a Simple mod that adds currently 2 new tool sets; Ender Pearl and Nether Star. The recipes are the same as the default tools It requires forge for mc1.7.2 Download Link There are still a lot of things I want to add to this mod and I hope to update it regularly. Constructive criticism both good and bad would be helpful as this is the first mod I made.
  7. whats a good tutorial on how to make items act as tools e.g. adding a pick axe? Thanks
  8. Thanks got it working, right now I am learning as I go it was due to caps in the file name and modid
  9. Do you mean on this line setTextureName("extratools:EnderShard"); I should change it to setTextureName("ExtraTools:EnderShard"); ? Ive already tried that and it didnt help
  10. I've been following the generic tutorial on the wiki but have run into issues when adding images to my mods. I had it working at one point but after I added another item it stopped working. Ive tried pretty much everything I could think of. but with no luck. Heres a image of the file tree and code. Please ask if you need anything else.
×
×
  • Create New...

Important Information

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