From c883a325ad9d8deb5770beb3a639a0b76bbfbeba Mon Sep 17 00:00:00 2001 From: alex Date: Tue, 8 Sep 2026 08:13:39 -0400 Subject: [PATCH] lane T merge fixups: name the roll-succeeded branch instead of its FUN_ id (clean-room); mark describe_i32 maybe_unused so the shim cross-builds --- docs/T-turn-driver.md | 2 +- include/generated/sots_addresses.h | 2 +- src/shim/hooks/player_turn.cpp | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/T-turn-driver.md b/docs/T-turn-driver.md index c60d8a9..fdca88b 100644 --- a/docs/T-turn-driver.md +++ b/docs/T-turn-driver.md @@ -122,7 +122,7 @@ near-zero progress**, and give that player savings and a research slider that de **≥ 1.5 × cost** in one turn — the guaranteed-completion path, so the outcome does not itself depend on a roll. One End Turn then fires the `OnTechResearched` site with the flag set. -That save would also, for the first time, be able to reach `FUN_00889d60` — the branch behind the +That save would also, for the first time, be able to reach `ServerPlayer_OnResearchRollSucceeded` — the branch behind the roll. Note what it costs if it fires: the plague branch draws a **second** RNG word (`NextInt`) and posts `EVENT_PLAGUE_OUTBREAK`; the rebellion branch allocates an `AIRebellion` at `ServerPlayer+0x3b8` and **cancels the current research**. Every coverage note in this repo up to now says "exactly one diff --git a/include/generated/sots_addresses.h b/include/generated/sots_addresses.h index 3d58d95..52c8f95 100644 --- a/include/generated/sots_addresses.h +++ b/include/generated/sots_addresses.h @@ -1,5 +1,5 @@ // GENERATED — do not edit. Facts about Sword of the Stars.exe (GOG 1.8.1). -// Source: sots-re ghidra/addresses.json @ afa8620, generated 2026-09-08 by tools/gen_addresses.py +// Source: sots-re ghidra/addresses.json @ 834eb09, generated 2026-09-08 by tools/gen_addresses.py // Runtime address = (uintptr_t)GetModuleHandle(NULL) + RVA (the exe is ASLR-relocated). #pragma once #include diff --git a/src/shim/hooks/player_turn.cpp b/src/shim/hooks/player_turn.cpp index 0e81180..f144b2e 100644 --- a/src/shim/hooks/player_turn.cpp +++ b/src/shim/hooks/player_turn.cpp @@ -222,7 +222,8 @@ void capture(void* player, float dt) { Tv describe_f32(const void* d, std::size_t n, unsigned) { return n >= 4 ? tv::f32(*static_cast(d)) : tv::struct_(); } -Tv describe_i32(const void* d, std::size_t n, unsigned) { +[[maybe_unused]] // Kept for the phase-2/3/6 regions that are guarded but not yet in the verdict (docs/T-turn-driver.md). +[[maybe_unused]] Tv describe_i32(const void* d, std::size_t n, unsigned) { return n >= 4 ? tv::i32(*static_cast(d)) : tv::struct_(); } Tv describe_per_turn(const void* d, std::size_t n, unsigned) {