PaperMC/paper-server
David Slovikosky c637868aef Fix missing chunks due to integer overflow
This patch fixes a bug in the EndIslandDensityFunction class where the distance
from 0,0 squared overflows the maximum size of an integer. The overflow leads
to hard chunk borders around 370,000 blocks from 0,0. After this cutoff there
is a few hundred thousand block gap before end land resuming to generate at
530,000 blocks from spawn. This is due to the integer flipping back and forth.

The fix for the issue is quite simple, casting chunk coordinates to longs
allows the distance calculation to avoid overflow and work as intended.

This issue is being tracked in Mojira ticket MC-159283
2020-06-09 00:10:03 -07:00
..
patches/sources Fix missing chunks due to integer overflow 2020-06-09 00:10:03 -07:00
src Fix CraftScheduler#runTaskTimerAsynchronously(Plugin, Consumer<BukkitTask>, long, long) scheduling a non-repeating task instead of a repeating one. 2020-06-12 01:38:06 +03:00
.gitignore Setup Gradle project 2020-12-10 20:54:19 -08:00
build.gradle.kts Implement Mob Goal API 2020-01-03 16:26:19 +01:00
LGPL.txt
LICENCE.txt