PAR-170
0
chestshop_shop spatial query support: location index + region/chunk/distance read API
PlannedLowUnassignedTreasuryFeature
Part of PAR-166 (spin out /find). Data-layer gap for spatial features.
Legacy chestshop-database queries shops by chunk / bounding box (selectShopsInChunk, selectShopsInBoundingBox) to render holograms per loaded chunk, and computes distance for the DISTANCE sort. Treasury's chestshop_shop is indexed by item_key/material/owner only — there is no spatial index on (world, sign_x, sign_z), and no region read path.
Do:
- New
economy-schemamigration: add a(world, sign_x, sign_z)index tochestshop_shop(theuq_shop_locationunique key is(world, sign_x, sign_y, sign_z)— leading-column prefix helps point lookups but a 2D x/z index serves region scans better). - Read API (mapper + endpoint or
MarketApiread method) for "shops in world within bounding box / chunk" so the new plugin can render holograms and resolve distance without scanning the whole table.
Scope check: if holograms end up rendered purely from a plugin-local cache rather than querying Treasury per chunk, only the distance-sort path matters — confirm with the holograms sub-issue before building the full region API.
Resources
- commit6902bdf Add the /find shop-registry read API + schema foundation (PAR-5)ParadauxIO/hibernia-economy
Comments
No comments yet.
Activity
- ParadauxIO linked a commit — Commit 6902bdf — Add the /find shop-registry read API + schema foundation (PAR-5)
- tesks changed status to Status → Planned
- tesks created the issue