Merge pull request #117 from mapcraftlabs/fix/find-tile-bug

Fix bug in find_tiles in the python V3 code
This commit is contained in:
Brandon Liu
2023-01-30 03:42:19 +08:00
committed by GitHub
2 changed files with 2 additions and 1 deletions

View File

@@ -85,7 +85,7 @@ def tileid_to_zxy(tile_id):
def find_tile(entries, tile_id):
m = 0
n = len(entries) - 1
while m < n:
while m <= n:
k = (n + m) >> 1
c = tile_id - entries[k].tile_id
if c > 0:

View File

@@ -1,3 +1,4 @@
import json
from collections import namedtuple