public unsafe void Split(BoundingBox2D *childBoxes, ref IMy2DClipmapNodeHandler[] children) { for (int i = 0; i < 4; ++i) { children[i].Init(m_parent, (Coords.X << 1) + (i & 1), (Coords.Y << 1) + ((i >> 1) & 1), Lod - 1, ref childBoxes[i]); } }
public unsafe void Split(BoundingBox2D* childBoxes, ref IMy2DClipmapNodeHandler[] children) { m_split = true; for (int i = 0; i < 4; ++i) children[i].Init(m_manager, (Coords.X << 1) + (i & 1), (Coords.Y << 1) + ((i >> 1) & 1), Lod - 1, ref childBoxes[i]); if (EnvironmentSector != null) // if we have so do our children. { for (int i = 0; i < 4; ++i) { m_children[i] = (MyPlanetEnvironmentClipmapProxy)children[i]; m_children[i].m_parent = this; } } }