mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-01-27 09:24:53 +00:00
fixed bucketer
This commit is contained in:
parent
2d74cfe6c4
commit
949ee1b382
@ -1692,7 +1692,7 @@ EX ld raddif(ld a, ld b) {
|
||||
EX int bucket_scale = 10000;
|
||||
|
||||
EX unsigned bucketer(ld x) {
|
||||
return (unsigned) (long long) (floor(x * bucket_scale));
|
||||
return (unsigned) (long long) (floor(x * bucket_scale + .5));
|
||||
}
|
||||
|
||||
EX unsigned bucketer(hyperpoint h) {
|
||||
|
Loading…
Reference in New Issue
Block a user