Added option and example for access transformers

This commit is contained in:
Johann Bernhardt committed 2021-11-07 00:25:02 +01:00
1 parent 0bbd636bc6
commit 4c37051951
4 files changed
+33

No files matched your search

@@ -1,6 +1,9 @@
package com.myname.mymodid;
import cpw.mods.fml.common.event.*;
import net.minecraft.block.material.Material;
import net.minecraft.client.gui.GuiScreenBook;
import net.minecraft.init.Blocks;
public class CommonProxy {
@@ -20,7 +23,14 @@ public class CommonProxy {
// postInit "Handle interaction with other mods, complete your setup based on this."
public void postInit(FMLPostInitializationEvent event) {
// Access originally package-private subclass
GuiScreenBook.NextPageButton button = null;
// Access originally private field
Material air = Blocks.air.blockMaterial;
// Access originally protected method
Blocks.air.disableStats();
}
public void serverAboutToStart(FMLServerAboutToStartEvent event) {