Reduce chunk size

This commit is contained in:
tobspr 2020-05-19 00:00:13 +02:00
parent 14edac0f93
commit 2968fe3788
2 changed files with 3 additions and 3 deletions

View File

@ -27,7 +27,7 @@ export const globalConfig = {
maximumTickRate: 500,
// Map
mapChunkSize: 32,
mapChunkSize: 16,
mapChunkPrerenderMinZoom: 1.3,
mapChunkOverviewMinZoom: 0.7,

View File

@ -244,14 +244,14 @@ export class MapChunk {
// Determine how likely it is that there is a color patch
const colorPatchChance = 0.9 - clamp(distanceToOriginInChunks / 25, 0, 1) * 0.5;
if (rng.next() < colorPatchChance) {
if (rng.next() < colorPatchChance / 4) {
const colorPatchSize = Math_max(2, Math_round(1 + clamp(distanceToOriginInChunks / 8, 0, 4)));
this.internalGenerateColorPatch(rng, colorPatchSize, distanceToOriginInChunks);
}
// Determine how likely it is that there is a shape patch
const shapePatchChance = 0.9 - clamp(distanceToOriginInChunks / 25, 0, 1) * 0.5;
if (rng.next() < shapePatchChance) {
if (rng.next() < shapePatchChance / 4) {
const shapePatchSize = Math_max(2, Math_round(1 + clamp(distanceToOriginInChunks / 8, 0, 4)));
this.internalGenerateShapePatch(rng, shapePatchSize, distanceToOriginInChunks);
}