feat: move func to calc package
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user