Skip to main content

quantize_coord

Function quantize_coord 

Source
pub fn quantize_coord(coord: f64) -> i64
Expand description

Quantize a coordinate value to a long integer.

This matches vanilla’s Climate.quantizeCoord() exactly: (long)(coord * 10000.0F)

CRITICAL: The input is cast to f32 first, then multiplied, then cast to i64. This ensures bit-exact matching with vanilla Java’s float behavior.