summaryrefslogtreecommitdiff
path: root/server/coords.go
diff options
context:
space:
mode:
Diffstat (limited to 'server/coords.go')
-rw-r--r--server/coords.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/server/coords.go b/server/coords.go
index ebe71c9..7add606 100644
--- a/server/coords.go
+++ b/server/coords.go
@@ -17,6 +17,10 @@ type entityPos struct {
X, Y, Z entityCoord
}
+func fromFloat(f float64) entityCoord {
+ return entityCoord(f * 32)
+}
+
func entityToBlock(pos entityPos) blockPos {
return blockPos {
blockCoord(pos.X >> 5),