Jump to content

[1.7.10] Patching Minecraft code


Recommended Posts

I'm backporting the 1.8 Zombie Pigman AI to 1.7.10. To do this, I need to replace EntityPigZombie's isAIEnabled() method with one that returns true instead of false. I've Googled thoroughly, and found a vast body of conflicting, irrelevant, and/or outdated information on the topic.

 

What is the current recommended best practice for obtaining the obfuscated names, and then for creating and applying a patch?

Link to comment
Share on other sites

You dont, thats the best practice, backporting is bad enough as is.

You can use ASM, but core modding is bad and most likely will break things if you do not know what you are doing.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Link to comment
Share on other sites

You might be able to figure out a way to fake it by using events. Basically, maybe you could use an event to cancel the 1.7.10 update code, and then go off and run the methods that call the AI.

 

I haven't looked through the whole thing, so maybe there is something that would prevent this approach, but in the end the AI is just some code that is called each tick to check whether it should start or stop doing various things. '

 

Yet another approach would be to create a custom entity and replace the vanilla zombie pigman with the custom entity.

Check out my tutorials here: http://jabelarminecraft.blogspot.com/

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



×
×
  • Create New...

Important Information

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