Advertisement
bobmarley12345

Disable minecraft 1.6.4 AABB pool when using heavily AABB-intensive functions

May 25th, 2022
542
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. private static boolean disabled;
  2. private static int prevCleans;
  3. public static void disableAABBPool() {
  4.     if (disabled) {
  5.         return;
  6.     }
  7.    
  8.     prevCleans = AxisAlignedBB.func_72332_a().field_72301_f;
  9.     AxisAlignedBB.func_72332_a().field_72301_f = 0;
  10.     disabled = true;
  11. }
  12. public static void enableAABBPool() {
  13.     if (disabled) {
  14.         AxisAlignedBB.func_72332_a().field_72301_f = prevCleans;
  15.         prevCleans = 0;
  16.         disabled = false;
  17.     }
  18. }
Advertisement
RAW Paste Data Copied
Advertisement