public static bool CheckEnvironmentVolumes(
        this Transform transform,
        Vector3 pos,
        Quaternion rot,
        Vector3 scale,
        EnvironmentType type)
    {
        List <EnvironmentVolume> list = (List <EnvironmentVolume>)Pool.GetList <EnvironmentVolume>();

        ((Component)transform).GetComponentsInChildren <EnvironmentVolume>(true, (List <M0>)list);
        for (int index = 0; index < list.Count; ++index)
        {
            EnvironmentVolume environmentVolume = list[index];
            OBB obb;
            ((OBB) ref obb).\u002Ector(((Component)environmentVolume).get_transform(), new Bounds(environmentVolume.Center, environmentVolume.Size));
            ((OBB) ref obb).Transform(pos, scale, rot);
            if (EnvironmentManager.Check(obb, type))
            {
                // ISSUE: cast to a reference type
                Pool.FreeList <EnvironmentVolume>((List <M0>&) ref list);
                return(true);
            }
        }
        // ISSUE: cast to a reference type
        Pool.FreeList <EnvironmentVolume>((List <M0>&) ref list);
        return(false);
    }
    public static bool CheckEnvironmentVolumes(this Transform transform, Vector3 pos, Quaternion rot, Vector3 scale, EnvironmentType type)
    {
        List <EnvironmentVolume> obj = Pool.GetList <EnvironmentVolume>();

        transform.GetComponentsInChildren(true, obj);
        for (int i = 0; i < obj.Count; i++)
        {
            EnvironmentVolume environmentVolume = obj[i];
            OBB obb = new OBB(environmentVolume.transform, new Bounds(environmentVolume.Center, environmentVolume.Size));
            obb.Transform(pos, scale, rot);
            if (EnvironmentManager.Check(obb, type))
            {
                Pool.FreeList(ref obj);
                return(true);
            }
        }
        Pool.FreeList(ref obj);
        return(false);
    }
    public static bool CheckEnvironmentVolumes(this Transform transform, Vector3 pos, Quaternion rot, Vector3 scale, EnvironmentType type)
    {
        List <EnvironmentVolume> list = Pool.GetList <EnvironmentVolume>();

        transform.GetComponentsInChildren <EnvironmentVolume>(true, list);
        for (int i = 0; i < list.Count; i++)
        {
            EnvironmentVolume item = list[i];
            OBB oBB = new OBB(item.transform, new Bounds(item.Center, item.Size));
            oBB.Transform(pos, scale, rot);
            if (EnvironmentManager.Check(oBB, type))
            {
                Pool.FreeList <EnvironmentVolume>(ref list);
                return(true);
            }
        }
        Pool.FreeList <EnvironmentVolume>(ref list);
        return(false);
    }