Add Pinwheel Clause support for zone-based encounters in route groups

Allows each sub-zone within a route group to have its own independent
encounter when the Pinwheel Clause rule is enabled (default on), instead
of the entire group sharing a single encounter.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-07 20:22:36 +01:00
parent 0b874a6816
commit 4fb6d43305
16 changed files with 233 additions and 22 deletions

View File

@@ -109,9 +109,14 @@ async def upsert_routes(
game_id=game_id,
order=child["order"],
parent_route_id=parent_id,
pinwheel_zone=child.get("pinwheel_zone"),
).on_conflict_do_update(
constraint="uq_routes_game_name",
set_={"order": child["order"], "parent_route_id": parent_id},
set_={
"order": child["order"],
"parent_route_id": parent_id,
"pinwheel_zone": child.get("pinwheel_zone"),
},
)
await session.execute(stmt)