VillageScreen.PortRequests exposes five port quota structs where the game holds six. The missing one is always the last port, Moti Aro, so any plugin reading Kingsmarch shipping quotas silently loses a destination.
Reproduction
Enter Kingsmarch, open the shipping screen, and count the entries:
var vs = GameController.IngameState.IngameUi.VillageScreen;
LogMessage($"{vs.PortRequests?.Count}"); // 5, with six ports shown in the UI
What's actually there
The six quota structs are one contiguous array with a 24-byte stride, and the sixth is populated normally — the reader just stops one short. Materialising entries past the end of the list:
var list = vs.PortRequests;
var port = GameController.Game.GetObject<VillagePortRequest>(list[0].Address + 24L * list.Count);
- index 5 (
list.Count) — a well-formed request list; at the time of testing, Wheat 30,000 at +40% and Corn 31,000 at +100%, matching what the UI showed for Moti Aro
- index 6 — empty, i.e. the array's terminator
- index 7+ — garbage
So the array's real length is six and the count used to build the list is one too small.
Environment
ExileCore.dll 1.0.0+5a8a10a6d0d92aaee5a8ea0f23cbd2d69b3a8113-dirty, dated 2026-08-25
- Path of Exile 1, Kingsmarch / Settlers content
Workaround
Plugins can read the last port straight from the array, indexing off list.Count rather than a hardcoded 5, so the read falls back cleanly once this is fixed: Matejko-poe/VillageManager#2
Happy to test a patched build against the same shipment screen if that helps.
VillageScreen.PortRequestsexposes five port quota structs where the game holds six. The missing one is always the last port, Moti Aro, so any plugin reading Kingsmarch shipping quotas silently loses a destination.Reproduction
Enter Kingsmarch, open the shipping screen, and count the entries:
What's actually there
The six quota structs are one contiguous array with a 24-byte stride, and the sixth is populated normally — the reader just stops one short. Materialising entries past the end of the list:
list.Count) — a well-formed request list; at the time of testing, Wheat 30,000 at +40% and Corn 31,000 at +100%, matching what the UI showed for Moti AroSo the array's real length is six and the count used to build the list is one too small.
Environment
ExileCore.dll1.0.0+5a8a10a6d0d92aaee5a8ea0f23cbd2d69b3a8113-dirty, dated 2026-08-25Workaround
Plugins can read the last port straight from the array, indexing off
list.Countrather than a hardcoded 5, so the read falls back cleanly once this is fixed: Matejko-poe/VillageManager#2Happy to test a patched build against the same shipment screen if that helps.