unreal.GridSettings

class unreal.GridSettings

Bases: StructBase

Grid configuration: cell size, 2D-vs-3D mode, and grid origin offset. Used everywhere a mesh is split on a regular grid – WP-aligned compiled sections, complexity-driven subsection splits, and PIE placeholders. Hashed in field-declaration order via GatherDependencies; new attributes (padding, …) extend this struct rather than threading parallel parameters.

C++ Source:

  • Plugin: MeshPartition

  • Module: MeshPartition

  • File: MeshPartitionGridSettings.h

Editor Properties: (see get_editor_property/set_editor_property)

  • cell_size (uint32): [Read-Only] Cell size in unreal units. 0 means “no grid splitting” (single-section path).

  • is2d (bool): [Read-Only] True when the grid collapses Z into a single column per X/Y cell (matches WP runtime LHGrid Is2D).

  • world_origin_offset (Vector): [Read-Only] World-space anchor of the grid (typically FFixedGridInfo::Origin). Consumers must shift by the MeshPartition actor’s LocalToWorld translation before snapping mesh-local bounds – see GridHelpers::ComputeLocalAnchor.