// [TypeInfo RVA: 0x0]
public class CullingManagerSimple : MonoBehaviour
{
	public System.Collections.Generic.List<UnityEngine.GameObject> objectsToCull; // 0x20
	public float globalCullDistance; // 0x28
	public UnityEngine.Transform cullTarget; // 0x30
	public float updateInterval; // 0x38
	public bool disableWholeObject; // 0x3C
	private System.Collections.Generic.Dictionary<UnityEngine.GameObject,System.Boolean> cullStates; // 0x40
	private float timer; // 0x48

	// RVA: 0x31FDF1C VA: 0x78188E8F1C
	private void Start();
	/*
	 *   undefined *puVar1;
	 *   undefined *puVar2;
	 *   undefined *puVar3;
	 *   long lVar4;
	 *   ulong uVar5;
	 *   void *extraout_x1;
	 *   void **ppvVar6;
	 *   void *pvVar7;
	 *   float fVar8;
	 *   undefined8 uStack_48;
	 *   undefined8 uStack_40;
	 *   undefined8 uStack_38;
	 *
	 *   puVar1 = typeinfo_ptr_UnityEngine_CoreModule_Object_6FC07E8;
	 *   if ((bRam000000000754a774 & 1) == 0) {
	 *     func_0x031fdc8c(PTR_DAT_070c0918);
	 *     func_0x031fdc8c(PTR_DAT_070c0920);
	 *     func_0x031fdc8c(PTR_DAT_070c0938);
	 *     func_0x031fdc8c(PTR_DAT_070c0948);
	 *     func_0x031fdc8c(PTR_DAT_070c0950);
	 *     func_0x031fdc8c(typeinfo_ptr_UnityEngine_CoreModule_Object_6FC07E8);
	 *     bRam000000000754a774 = 1;
	 *     methodInfo = extraout_x1;
	 *   }
	 *   lVar4 = *(long *)puVar1;
	 *   uStack_48 = 0;
	 *   uStack_40 = 0;
	 *   ppvVar6 = &this.cullTarget;
	 *   pvVar7 = *ppvVar6;
	 *   uStack_38 = 0;
	 *   if (*(int *)(lVar4 + 0xe4) == 0) {
	 *     func_0x031fde08(lVar4,methodInfo);
	 *   }
	 *   uVar5 = UnityEngine.Object.op_Equality(pvVar7,null);
	 *   if ((uVar5 & 1) != 0) {
	 *     pvVar7 = UnityEngine.Camera.get_main();
	 *     lVar4 = *(long *)puVar1;
	 *     if (*(int *)(lVar4 + 0xe4) == 0) {
	 *       func_0x031fde08(lVar4);
	 *     }
	 *     uVar5 = UnityEngine.Object.op_Inequality(pvVar7,null);
	 *     if ((uVar5 & 1) != 0) {
	 *       pvVar7 = UnityEngine.Camera.get_main();
	 *       if (pvVar7 == null) goto LAB_032fe0c0;
	 *       pvVar7 = UnityEngine.Component.get_transform(pvVar7);
	 *       *ppvVar6 = pvVar7;
	 *       func_0x031fdc38(ppvVar6,pvVar7);
	 *     }
	 *   }
	 *   puVar3 = PTR_DAT_070c0938;
	 *   puVar2 = PTR_DAT_070c0920;
	 *   puVar1 = PTR_DAT_070c0918;
	 *   if (this.objectsToCull != null) {
	 *     func_0x03f2e1a8(&uStack_48,this.objectsToCull,*(undefined8 *)PTR_DAT_070c0950);
	 *     while( true ) {
	 *       uVar5 = func_0x05018cac(&uStack_48,*(undefined8 *)puVar3);
	 *       if ((uVar5 & 1) == 0) {
	 *         func_0x05018ca8(&uStack_48,*(undefined8 *)puVar2);
	 *         fVar8 = Random.Range(0.0,this.updateInterval);
	 *         this.timer = fVar8;
	 *         return;
	 *       }
	 *       if (this.cullStates == null) break;
	 *       func_0x04e05044(this.cullStates,uStack_38,0,*(undefined8 *)puVar1);
	 *     }
	 *     IL2CPP.ThrowNullReferenceException();
	 *   }
	 * LAB_032fe0c0:
	 *   IL2CPP.ThrowNullReferenceException();
	 */
	// RVA: 0x31FE11C VA: 0x78188E911C
	private void Update();
	/*
	 *   undefined *puVar1;
	 *   undefined *puVar2;
	 *   undefined *puVar3;
	 *   undefined *puVar4;
	 *   undefined *puVar5;
	 *   long lVar6;
	 *   ulong uVar7;
	 *   void *pvVar8;
	 *   void *extraout_x1;
	 *   void *in_x3;
	 *   void *pvVar9;
	 *   float fVar10;
	 *   float fVar11;
	 *   float fVar12;
	 *   UnityEngine_Vector3 UVar13;
	 *   UnityEngine_Vector3 UVar14;
	 *   undefined8 uStack_b8;
	 *   undefined8 *puStack_b0;
	 *   void *pvStack_a8;
	 *   undefined8 uStack_a0;
	 *   undefined8 uStack_98;
	 *   void *pvStack_90;
	 *
	 *   puVar2 = typeinfo_ptr_UnityEngine_CoreModule_Object_6FC07E8;
	 *   if ((bRam000000000754a775 & 1) == 0) {
	 *     func_0x031fdc8c(PTR_DAT_070c0e20);
	 *     func_0x031fdc8c(PTR_DAT_070c0918);
	 *     func_0x031fdc8c(PTR_DAT_070c0920);
	 *     func_0x031fdc8c(PTR_DAT_070c0938);
	 *     func_0x031fdc8c(PTR_DAT_070c0948);
	 *     func_0x031fdc8c(PTR_DAT_070c0950);
	 *     func_0x031fdc8c(typeinfo_ptr_UnityEngine_CoreModule_Object_6FC07E8);
	 *     bRam000000000754a775 = 1;
	 *     methodInfo = extraout_x1;
	 *   }
	 *   lVar6 = *(long *)puVar2;
	 *   pvVar9 = this.cullTarget;
	 *   uStack_a0 = 0;
	 *   uStack_98 = 0;
	 *   pvStack_90 = null;
	 *   if (*(int *)(lVar6 + 0xe4) == 0) {
	 *     func_0x031fde08(lVar6,methodInfo);
	 *   }
	 *   uVar7 = UnityEngine.Object.op_Equality(pvVar9,null);
	 *   if ((uVar7 & 1) == 0) {
	 *     fVar12 = this.timer;
	 *     fVar10 = UnityEngine.Time.get_deltaTime();
	 *     fVar12 = fVar12 - fVar10;
	 *     this.timer = fVar12;
	 *     if (fVar12 <= 0.0) {
	 *       this.timer = this.updateInterval;
	 *       if (this.cullTarget != null) {
	 *         UVar13 = UnityEngine.Transform.get_position(this.cullTarget);
	 *         if (this.objectsToCull != null) {
	 *           func_0x03f2e1a8(&uStack_b8,this.objectsToCull,*(undefined8 *)PTR_DAT_070c0950);
	 *           puVar5 = PTR_DAT_070c0e20;
	 *           puVar4 = PTR_DAT_070c0938;
	 *           puVar3 = PTR_DAT_070c0918;
	 *           puVar1 = typeinfo_ptr_mscorlib_Math_6FC0738;
	 *           uStack_98 = puStack_b0;
	 *           uStack_a0 = uStack_b8;
	 *           pvStack_90 = pvStack_a8;
	 *           puStack_b0 = &uStack_a0;
	 *           uStack_b8 = 0;
	 *           while( true ) {
	 *             do {
	 *               uVar7 = func_0x05018cac(&uStack_a0,*(undefined8 *)puVar4);
	 *               pvVar9 = pvStack_90;
	 *               if ((uVar7 & 1) == 0) {
	 *                 func_0x05018ca8(&uStack_a0,*(undefined8 *)PTR_DAT_070c0920);
	 *                 return;
	 *               }
	 *               if (*(int *)(*(long *)puVar2 + 0xe4) == 0) {
	 *                 func_0x031fde08();
	 *               }
	 *               uVar7 = UnityEngine.Object.op_Equality(pvVar9,null);
	 *             } while ((uVar7 & 1) != 0);
	 *             if (pvVar9 == null) break;
	 *             pvVar8 = UnityEngine.GameObject.get_transform(pvVar9);
	 *             if (pvVar8 == null) {
	 *               IL2CPP.ThrowNullReferenceException();
	 *             }
	 *             UVar14 = UnityEngine.Transform.get_position(pvVar8);
	 *             if (cRam000000000754a7c9 == '\0') {
	 *               func_0x031fdc8c(puVar1);
	 *               cRam000000000754a7c9 = '\x01';
	 *             }
	 *             if (*(int *)(*(long *)puVar1 + 0xe4) == 0) {
	 *               func_0x031fde08();
	 *             }
	 *             fVar10 = UVar14.y - UVar13.y;
	 *             fVar12 = UVar14.x - UVar13.x;
	 *             pvVar8 = this.cullStates;
	 *             fVar11 = UVar14.z - UVar13.z;
	 *             if (SQRT(fVar11 * fVar11 + fVar12 * fVar12 + fVar10 * fVar10) <=
	 *                 this.globalCullDistance) {
	 *               if (pvVar8 == null) {
	 *                 IL2CPP.ThrowNullReferenceException();
	 *               }
	 *               uVar7 = func_0x04e04fd0(pvVar8,pvVar9,*(undefined8 *)puVar5);
	 *               if ((uVar7 & 1) != 0) {
	 *                 CullingManagerSimple.ToggleObject(this,pvVar9,true);
	 *                 if (this.cullStates == null) {
	 *                   IL2CPP.ThrowNullReferenceException();
	 *                 }
	 *                 in_x3 = *(void **)puVar3;
	 *                 func_0x04e05044(this.cullStates,pvVar9,0);
	 *               }
	 *             }
	 *             else {
	 *               if (pvVar8 == null) {
	 *                 IL2CPP.ThrowNullReferenceException();
	 *               }
	 *               uVar7 = func_0x04e04fd0(pvVar8,pvVar9,*(undefined8 *)puVar5);
	 *               if ((uVar7 & 1) == 0) {
	 *                 CullingManagerSimple.ToggleObject(this,pvVar9,false)
	 *                 ;
	 *                 if (this.cullStates == null) {
	 *                   IL2CPP.ThrowNullReferenceException();
	 *                 }
	 *                 in_x3 = *(void **)puVar3;
	 *                 func_0x04e05044(this.cullStates,pvVar9,1);
	 *               }
	 *             }
	 *           }
	 *           IL2CPP.ThrowNullReferenceException();
	 *         }
	 *       }
	 *       IL2CPP.ThrowNullReferenceException();
	 *     }
	 *   }
	 *   return;
	 */
	// RVA: 0x31FE4AC VA: 0x78188E94AC
	private void ToggleObject(UnityEngine.GameObject obj, bool state);
	/*
	 *   ulong uVar1;
	 *   long lVar2;
	 *   void *pvStack_40;
	 *   void *pvStack_38;
	 *   void *pvStack_28;
	 *
	 *   if ((bRam000000000754a776 & 1) == 0) {
	 *     func_0x031fdc8c(PTR_DAT_070c0e28);
	 *     func_0x031fdc8c(PTR_DAT_070c0e30);
	 *     func_0x031fdc8c(PTR_DAT_070c0e38);
	 *     bRam000000000754a776 = 1;
	 *   }
	 *   pvStack_28 = null;
	 *   pvStack_40 = null;
	 *   pvStack_38 = null;
	 *   if (this.disableWholeObject == false) {
	 *     if (obj != null) {
	 *       uVar1 = func_0x037f4130(obj,&pvStack_28,*(undefined8 *)PTR_DAT_070c0e28);
	 *       if ((uVar1 & 1) != 0) {
	 *         if (pvStack_28 == null) goto LAB_032fe5f4;
	 *         UnityEngine.InputSystem.OnScreen.OnScreenStick.Behaviour.set_enabled(pvStack_28,state);
	 *       }
	 *       uVar1 = func_0x037f4130(obj,&pvStack_38,*(undefined8 *)PTR_DAT_070c0e38);
	 *       if ((uVar1 & 1) != 0) {
	 *         if (pvStack_38 == null) goto LAB_032fe5f4;
	 *         UnityEngine.Renderer.set_enabled(pvStack_38,state);
	 *       }
	 *       uVar1 = func_0x037f4130(obj,&pvStack_40,*(undefined8 *)PTR_DAT_070c0e30);
	 *       if ((uVar1 & 1) == 0) {
	 *         return;
	 *       }
	 *       if (state) {
	 *         if (pvStack_40 != null) {
	 *           UnityEngine.ParticleSystem.Play(pvStack_40);
	 *           return;
	 *         }
	 *       }
	 *       else if (pvStack_40 != null) {
	 *         UnityEngine.ParticleSystem.Stop(pvStack_40,true,0);
	 *         return;
	 *       }
	 *     }
	 *   }
	 *   else if (obj != null) {
	 *     if ((bRam000000000755f7e0 & 1) == 0) {
	 *       func_0x031fdc8c(PTR_DAT_0714f3e0,state,0);
	 *       bRam000000000755f7e0 = 1;
	 *     }
	 *     if (obj == null) {
	 *       IL2CPP.ThrowNullReferenceException();
	 *     }
	 *     lVar2 = *(long *)((long)obj + 0x10);
	 *     if (lVar2 == 0) {
	 *       UnityEngine.Bindings.ThrowHelper.ThrowNullReferenceException(obj);
	 *     }
	 *     if (pcRam000000000755f860 == null) {
	 *       pcRam000000000755f860 = (code *)func_0x031fdc50(&UNK_0138da18);
	 *     }
	 *     (*pcRam000000000755f860)(lVar2,state);
	 *     return;
	 *   }
	 * LAB_032fe5f4:
	 *   IL2CPP.ThrowNullReferenceException();
	 */
	// RVA: 0x31FE5F8 VA: 0x78188E95F8
	public void .ctor();
	/*
	 *   undefined *puVar1;
	 *   undefined *puVar2;
	 *   undefined *puVar3;
	 *   undefined *puVar4;
	 *   void *pvVar5;
	 *   undefined8 uVar6;
	 *   void *extraout_x1;
	 *
	 *   puVar4 = PTR_DAT_070c0aa0;
	 *   puVar3 = PTR_DAT_070c0a88;
	 *   puVar2 = PTR_DAT_070c09e0;
	 *   puVar1 = PTR_DAT_070c09c8;
	 *   if ((bRam000000000754a777 & 1) == 0) {
	 *     func_0x031fdc8c(PTR_DAT_070c0a88);
	 *     func_0x031fdc8c(PTR_DAT_070c0aa0);
	 *     func_0x031fdc8c(PTR_DAT_070c09c8);
	 *     func_0x031fdc8c(PTR_DAT_070c09e0);
	 *     bRam000000000754a777 = 1;
	 *     methodInfo = extraout_x1;
	 *   }
	 *   pvVar5 = (void *)func_0x031fdf24(*(undefined8 *)puVar2,methodInfo);
	 *   func_0x03f2ce9c(pvVar5,*(undefined8 *)puVar1);
	 *   this.objectsToCull = pvVar5;
	 *   func_0x031fdc38(&this.objectsToCull,pvVar5);
	 *   uVar6 = *(undefined8 *)puVar4;
	 *   this.globalCullDistance = 40.0;
	 *   this.updateInterval = 0.5;
	 *   this.disableWholeObject = true;
	 *   pvVar5 = (void *)func_0x031fdf24(uVar6);
	 *   func_0x04e046bc(pvVar5,*(undefined8 *)puVar3);
	 *   this.cullStates = pvVar5;
	 *   func_0x031fdc38(&this.cullStates,pvVar5);
	 *   puVar1 = typeinfo_ptr_UnityEngine_CoreModule_Object_6FC07E8;
	 *   if ((bRam000000000755f76f & 1) == 0) {
	 *     func_0x031fdc8c(typeinfo_ptr_UnityEngine_CoreModule_Object_6FC07E8,0);
	 *     bRam000000000755f76f = 1;
	 *   }
	 *   if (*(int *)(*(long *)puVar1 + 0xe4) == 0) {
	 *     func_0x031fde08();
	 *   }
	 *   return;
	 */
}
