Improved biome generation, get grass color from gradient interpolation, improved performance of generation, try to recreate grass colors from imported chunks, closes #2845, closes #1792

This commit is contained in:
Shoghi Cervantes
2015-06-07 15:17:02 +02:00
parent d881dbf1a2
commit cbb1c55a06
23 changed files with 142 additions and 126 deletions

View File

@ -1237,8 +1237,8 @@ class Server{
$order = [];
for($X = -4; $X <= 4; ++$X){
for($Z = -4; $Z <= 4; ++$Z){
for($X = -3; $X <= 3; ++$X){
for($Z = -3; $Z <= 3; ++$Z){
$distance = $X ** 2 + $Z ** 2;
$chunkX = $X + $centerX;
$chunkZ = $Z + $centerZ;
@ -1251,7 +1251,7 @@ class Server{
foreach($order as $index => $distance){
Level::getXZ($index, $chunkX, $chunkZ);
$level->generateChunk($chunkX, $chunkZ, true);
$level->populateChunk($chunkX, $chunkZ, true);
}
return true;