Posted July 9, 20178 yr I want to do something when a particular vanilla block (dirt) is getting rained on. Any clue how to detect when a vanilla block is getting rained on? I looked over all the events and didn't see anything that seemed useful. Edited July 9, 20178 yr by Daeruin Added version
July 9, 20178 yr Depending on what version you're using, I'd use either a substitution alias or the newer method of simply overriding the block registry entries to replace the vanilla block with your own class. It should extend the vanilla block class, but then change the code in the random tick method to check the weather and do something accordingly.Note: I haven't tried the method of overriding vanilla blocks yet, and I know it's fairly new to Forge for 1.12, so there may be bugs, but try it out first and see if it works. Whatever Minecraft needs, it is most likely not yet another tool tier.
July 9, 20178 yr Author I'm using 1.10.2. I updated the post title accordingly. I have never heard of either of your suggestions. A quick Google search brings up only complaints about substitution aliases not working, and nothing relevant for overriding block registry entries. Can you point me to an explanation somewhere?
July 9, 20178 yr Honestly, I've never had much luck with substitution aliases, either. According to sources, it was finally fixed in 1.10.2, but I have no experience with that. The 1.12 registry overriding is much easier, but of course that's not available for 1.10.2. Hopefully someone else with more experience can help you figure out how to use substitution aliases (but the general idea is the same: it replaces all references of one block, such as the vanilla one, with your own class instead). Whatever Minecraft needs, it is most likely not yet another tool tier.
July 9, 20178 yr Author Well, I played around with substitution aliases with no luck. Any other ideas, or links to successful implementations, would be appreciated.
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.