Docs / Windows Location usefulness
Windows Location usefulness
Implements the Windows location usefulness brainstorm for _AugmentedIntelligence.
Why it matters
| Use | How |
|---|---|
| Local weather / storm desk | Sync fix → _WeatherHazards::SetLocation |
| Disaster proximity | Haversine rank of NWS/USGS/EONET/GDACS events |
| Geofences | Home/work/range enter-exit for context & policies |
| Directions priors | Distance + bearing for Movement / Pathfinding demos |
| Ballistics | Latitude for Coriolis (ShootingRange ELR) |
| Privacy | Mock/disabled by default; live Win32 Location only when enabled |
Commands
location status
location useful
location enable | disable
location mock on|off|set LAT LON [name]
location set LAT LON [name]
location get [refresh]
location weather
location hazards [radius_km]
location distance LAT LON
location directions LAT LON [name]
location geofence list|eval|add ID LAT LON R_M [name]|remove ID
location apply-weather
location save|load [path]
location context
Aliases: winloc …, geo …, geolocation ….
Related: directions to LAT LON, directions distance LAT LON.
Lua
print(ai_location_status())
local f = ai_location_get(false) -- {ok, lat, lon, accuracy_m, source, name}
print(ai_location_haversine_km(47.6, -122.3, 40.7, -74.0))
Files
WindowsLocation.hpp/.cpp— fix store, COM Location API, geofences, nearby disastersDirections.hpp/.cpp— thin routing surface over location- Offline:
data/location/last_fix.json
Privacy
- Starts disabled + mock (Seattle default, same as WeatherHazards).
location enable+mock off+get refreshattempts Windows Location API (ILocation/ILatLongReport).- Falls back to mock → last file fix → WeatherHazards location.
Build
Units are in _AugmentedIntelligence.vcxproj. Links locationapi.lib + ole32.lib on Windows.
Generated from the project markdown docs on 2026-07-24. This is a static, self-contained site.