Fix the error in the distance calculation function #58

Merged
CoCo_Sol merged 1 commit from fix-hex-error into main 2024-02-18 18:12:39 +00:00

View file

@ -256,7 +256,7 @@ impl<T: Number> HexPosition<T> {
size.0
* 3f32
.sqrt()
.mul_add(T::to_f32(self.0), 3f32.sqrt() / 2.0 * T::to_f32(self.0)),
.mul_add(T::to_f32(self.0), 3f32.sqrt() / 2.0 * T::to_f32(self.1)),
size.1 * (3.0 / 2.0 * T::to_f32(self.1)),
)
}