From 2c7109887bc45ac9bb425fd23bfa60cdf93297c3 Mon Sep 17 00:00:00 2001 From: autocommit Date: Mon, 27 Apr 2026 22:02:04 -0700 Subject: [PATCH] =?UTF-8?q?revert(turn-processor):=20=E2=8F=AA=EF=B8=8F=20?= =?UTF-8?q?Revert=20culture-port=20logic=20to=20restore=20pre-Rust=20port?= =?UTF-8?q?=20GDScript=20behavior=20and=20document=20floating-point=20dive?= =?UTF-8?q?rgence?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Lilith Autocommit --- .../engine/src/modules/management/turn_processor.gd | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/game/engine/src/modules/management/turn_processor.gd b/src/game/engine/src/modules/management/turn_processor.gd index a9888b90..e19e89ec 100644 --- a/src/game/engine/src/modules/management/turn_processor.gd +++ b/src/game/engine/src/modules/management/turn_processor.gd @@ -364,9 +364,14 @@ func _process_culture(player: RefCounted, game_map: RefCounted) -> void: continue var c: CityScript = city_ref as CityScript var tile_json: String = BuildableHelperScript.build_tile_yields_json(c, game_map) - # TEMPORARY R9 PARITY TEST: revert to pre-port GDScript multiplication - # to isolate the culture-port effect from other landed code (courier - # diplomacy, building ID reconciliation) between R6 and R7/R8. + # Culture-port to Rust (`process_culture_with_modifier`) attempted in + # R7/R8 but caused seed-divergence vs R6 baseline (R9 parity test + # reproduced R6 exactly when reverted to this GDScript path; R8 with + # Rust port diverged on every seed). Math LOOKED identical but the + # Rust call sequence produces different floating-point intermediate + # results than the GDScript-via-Variant round-trip path. Culture port + # remains TODO — see p1-39. The other Rail-1 ports (gold, research) + # pass parity and stay. var pre_culture: float = c.get_culture_stored() var can_expand: bool = c.process_culture(tile_json) var cult_pct: float = _sum_city_building_effect_float(c, "culture_percent")