feat: move func to calc package

This commit is contained in:
Ilia Denisov
2026-05-10 14:55:14 +02:00
parent 92413575f3
commit 408097e3aa
11 changed files with 21214 additions and 38 deletions
+2 -3
View File
@@ -4,8 +4,7 @@ import (
"fmt"
"math/rand"
"galaxy/util"
"galaxy/calc"
"galaxy/game/internal/generator/plotter"
)
@@ -59,7 +58,7 @@ func (m Map) NewCoordinate(deadZoneRaduis float64) (Coordinate, error) {
}
func (m Map) ShortDistance(from, to Coordinate) float64 {
return util.ShortDistance(m.Width, m.Height, from.X, from.Y, to.X, to.Y)
return calc.ShortDistance(m.Width, m.Height, from.X, from.Y, to.X, to.Y)
}
// RandI returns a random float64 value between min and max