Small World Engine API Reference - v0.76.20
    Preparing search index...

    Function clusterIndex

    • Flattens a 3D cluster cell coordinate into a linear index (X-major, then Y, then Z).

      Parameters

      • x: number

        Cell coordinate along the X axis.

      • y: number

        Cell coordinate along the Y axis.

      • z: number

        Cell coordinate along the Z axis (depth slice).

      • dims: ClusterGridDims

        Grid dimensions from computeClusterCounts().

      Returns number