Posted June 29, 201213 yr Is there a way to have block(and possibly items) be nonexistent when certain mods are present? An example would be disabling Copper ore and Tin ore (to cut down on block ids and keep from overloading the world gen with repeat ores) if IC2 or RedPower World are installed
June 29, 201213 yr try using the isModLoader function from ModLoader checking is a mod is loaded... http://calclavia.com/uploads/banner.png[/img]
June 29, 201213 yr Author I tried that... When it is used I can't gain access to the blocks to use them...
June 29, 201213 yr I tried that... When it is used I can't gain access to the blocks to use them... Try doing this: Block.blockList[iC2COPPERBLOCKID] = null; You just nullified their block Something like that should work. Not sure though. I don't get why you would want to disable their blocks. http://calclavia.com/uploads/banner.png[/img]
June 29, 201213 yr Make it configurable, and determine if you should gen based on if either of those mods exist. I do Forge for free, however the servers to run it arn't free, so anything is appreciated. Consider supporting the team on Patreon
June 29, 201213 yr Author Make it configurable, and determine if you should gen based on if either of those mods exist. Didn't think of that for the world gen...
June 29, 201213 yr Maybe check if IC2 is generating ores and if it is don't generate those ores? That's what Forestry does... http://calclavia.com/uploads/banner.png[/img]
June 29, 201213 yr Author Maybe check if IC2 is generating ores and if it is don't generate those ores? That's what Forestry does... How would I do that?
June 29, 201213 yr Author Quick update got the world gen turned of if certain mods are present now just need to know how to disable my blocks...
June 30, 201213 yr Just don't register them on load and they vanish. Use an if statement with block registers in them to determine if the block should be loaded or ignored. Should work just fine http://i577.photobucket.com/albums/ss215/bobstrong/ModBannerMed.png[/img]
June 30, 201213 yr Author like: if (b == false) { ModLoader.registerBlock(MYOREHERE); } so when b is true it doesn't load?
July 25, 201213 yr Try doing this: Block.blockList[iC2COPPERBLOCKID] = null; No, don't. Doing that to someone else's block looks like a good way to get NullPointerExceptions.
August 4, 201213 yr It is! So, what would happen if I did push that shiny red button over there? ... Really? ... Can I try it? ... Damn.
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.