Scripts: rm priviliged start

This commit is contained in:
Pieter Vander Vennet 2025-08-01 02:05:17 +02:00
parent 848ec121f1
commit b367c945dd

View file

@ -55,18 +55,13 @@ class GeneratePmTilesExtracts extends Script {
private* generateField(z: number, maxzoom?: number): Generator<Promise<void>> {
const boundary = 2 << (z - 1)
for (let x = boundary / 2; x < boundary; x++) {
// We first generate starting from the meridian, as this will prioritize Europe, where the dev is based
for (const promise of this.generateColumnIfNeeded(z, x, boundary, maxzoom)) {
yield promise
}
}
for (let x = 0; x < boundary; x++) {
for (const promise of this.generateColumnIfNeeded(z, x, boundary, maxzoom)) {
yield promise
}
}
}
private getFilename(z: number, x: number, y: number) {
@ -105,7 +100,7 @@ class GeneratePmTilesExtracts extends Script {
let estimate = 0
for (const key in OfflineBasemapManager.zoomelevels) {
const z: number = Number(key)
const boundary = 2 << (z - 1)
const boundary = 2 << z
estimate += boundary * boundary
}
console.log("Target dir is:", this.targetDir)