Browse Source

Merge pull request #7 from Robotia/patch-4

Introduce TileEntity GC (GarbageCollection) Flag
master
Yive 9 years ago
parent
commit
53b2daf3ca
  1. 12
      patches/net/minecraft/tileentity/TileEntity.java.patch

12
patches/net/minecraft/tileentity/TileEntity.java.patch

@ -15,6 +15,7 @@
- protected World worldObj; - protected World worldObj;
+ public static Map classToNameMap = new HashMap(); // Cauldron - private -> public + public static Map classToNameMap = new HashMap(); // Cauldron - private -> public
+ public World worldObj; // CraftBukkit - protected -> public + public World worldObj; // CraftBukkit - protected -> public
+ private boolean GC = false;
public int xCoord; public int xCoord;
public int yCoord; public int yCoord;
public int zCoord; public int zCoord;
@ -55,6 +56,17 @@
+ return null; + return null;
+ } + }
+ // CraftBukkit end + // CraftBukkit end
+ //KCauldron start
+ public boolean isGC() //Returns true if the chunk it is inside of has marked it for unloading
+ {
+ return this.GC;
+ }
+
+ public boolean setGC(boolean state) //Should never be touched by a mod. Would make it package-private but not sure if that would still work
+ {
+ this.GC = state;
+ }
+ // KCauldron end
+ +
// -- BEGIN FORGE PATCHES -- // -- BEGIN FORGE PATCHES --
/** /**

Loading…
Cancel
Save