feat(extract): Chunk-Zuordnung in Python und Beschriftungsliste lesen
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
a8817e2849
commit
c9e0615a88
4 files changed
+299
-1
No files matched your search
@@ -53,3 +53,8 @@ def parse_chunk_name(name: str) -> tuple[int, int] | None:
|
||||
if not match or int(match.group(2)) > CHUNKS_PER_SIDE:
|
||||
return None
|
||||
return CHUNK_COLUMNS.index(match.group(1).upper()), int(match.group(2)) - 1
|
||||
|
||||
|
||||
def chunk_for_world(x: float, y: float) -> tuple[int, int]:
|
||||
"""Spiegel von chunkForWorld in src/world/coords.js: i nach Osten, j von der Nordkante nach Süden."""
|
||||
return int((x - SLICE["x0"]) // CHUNK_SIZE), int((SLICE["y1"] - y) // CHUNK_SIZE)
|
||||
Reference in new issue
Block a user