summaryrefslogtreecommitdiff
path: root/src/constants.h
diff options
context:
space:
mode:
authorJens Rottmann <30634967+JRottm@users.noreply.github.com>2017-08-20 19:37:55 +0200
committerLoïc Blot <nerzhul@users.noreply.github.com>2017-08-20 19:37:55 +0200
commit9d8cb510b3ad398c4fcb214704a2c3a42e944e34 (patch)
tree51a1bf3985f64eac66e78cf53880186f919e2306 /src/constants.h
parentae9b5e00989756bb676429530dfe81039009001c (diff)
downloadminetest-9d8cb510b3ad398c4fcb214704a2c3a42e944e34.tar.gz
minetest-9d8cb510b3ad398c4fcb214704a2c3a42e944e34.tar.bz2
minetest-9d8cb510b3ad398c4fcb214704a2c3a42e944e34.zip
Change BS constant from implicit double to float (#6286)
the BS constant implicitly promotes all position calculations it is used in to double even though positions (= v3f) are only meant to be floats. There are many, many similar occurrences everywhere, but I'm not willing to hunt down all; I only fixed the little part I'm already familiar with.
Diffstat (limited to 'src/constants.h')
-rw-r--r--src/constants.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/constants.h b/src/constants.h
index dd5611ac7..4da66cc53 100644
--- a/src/constants.h
+++ b/src/constants.h
@@ -71,7 +71,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
// floating-point and integer positions, which potentially give wrong
// results. (negative coordinates, values between nodes, ...)
// Use floatToInt(p, BS) and intToFloat(p, BS).
-#define BS (10.0)
+#define BS 10.0f
// Dimension of a MapBlock
#define MAP_BLOCKSIZE 16