cpu_route_network
Retrieve a read-only road map of legal waypoints and hubs as graph nodes with edges for planning transport routes in the CPU game. Annotate nodes with grid distances from optional source or destination.
Instructions
The road map of the world (read-only): every legal waypoint — your revealed cells and all Hubs — as graph nodes (owner, hub flag, per-unit transit fee, pos, connected-component id) plus every hop the contract would accept as edges (within radius(a)+radius(b)−1 grid steps; default balance: own↔own 1 = adjacent only, own↔hub 3, hub↔hub 5). Foreign cells are never nodes: even a single foreign cell between two plain cells is a WALL — only a Hub reaches across. Different component ids show exactly that — no chain crosses today, goods stop at the border. Bridging is a strategic decision: a border Hub (it still needs an eligible landing point within reach on the far side), buying land across, or a detour — the sphere is closed, so a wall must encircle to truly seal. Pass from/towards to annotate each node with grid distances (a potential field to reason over). Routing over this map is YOUR job: pick the chain, then verify with cpu_quote_transport. WHEN: the heavy read — plan a journey or a big replan; for point checks while executing use the cheap cpu_next_hops.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | No | Optional source cell — annotates every waypoint with its grid distance from here. | |
| towards | No | Optional destination cell — annotates every waypoint with its remaining grid distance. |