block.near

Syntax

ind = block.near(fx,fy)

Get the index of the block closest to (fx, fy).

Returns:

ind - block index

Arguments:

fx - \(x\)-position in global coordinates.

fy - \(y\)-position in global coordinates.