Find the planet setups in an exported build

The registry scanned res://PlanetSetups for names ending ".tres". An export
does not ship those: text resources are converted to binary and the pack
carries "<name>.tres.remap", which ResourceLoader follows when asked for the
original path. So the scan found nothing in the web build, every planet drew
no setup, and since #211 the setup IS the garrison - every world in the
deployed game was deserted, with nothing logged to say why. Confirmed by
reading index.pck, which holds rocky_default.tres.remap and no .tres.

The suite runs from source, where the bug cannot occur, so the name
resolution is its own function and tested against the exact strings the pack
contains.

Also: the planning centre listed transporters and repair drones but
set_vessel_target() still refused anything not fleet-eligible, so both rows
had buttons that did nothing - the worst shape a refusal can take. Listing
and setting read the same rule now, and a standing order is only offered to
a crafter that can actually take it.

And two quests close the chain: the tentacle world, which the scanner will
not offer until the story hands it over, and the Warden itself.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019AJMdB7iuHuLFZM1aBu3GD
This commit is contained in:
Loïc Wisniewski 2026-09-07 13:55:41 +02:00
commit df4d5e35f9
6 changed files with 179 additions and 8 deletions

View file

@ -87,7 +87,17 @@ func _state_cases() -> bool:
return _fail("a transporter standing at a hub is counted %d times, expected once" \
% game_state.vessel_census(GameState.VESSEL_TRANSPORTER))
game_state.remove_buildings_of_type(GameState.BUILDING_TRANSPORT_HUB)
print("support craft are plannable, and counted where they stand")
# Listed is not enough - the buttons have to move the number. #221 left
# the setter reading the old fleet-eligible rule, so both rows appeared
# with controls that did nothing at all.
for support in [GameState.VESSEL_TRANSPORTER, GameState.REPAIR_DRONE]:
if game_state.adjust_vessel_target(support, 2) != 2:
return _fail("'%s' is listed in the planning centre but its target cannot be raised" \
% support)
if game_state.vessel_target(support) != 2:
return _fail("'%s' target did not stick at 2" % support)
game_state.set_vessel_target(support, 0)
print("support craft are plannable, settable, and counted where they stand")
game_state.fleet_vessel_types = PackedStringArray([interceptor, interceptor])
game_state.stored_vessels.append(interceptor)
game_state.set_garrison_desired(outpost_id, interceptor, 1)