feat: make the radiator report its own internal state

v1.1.0 loaded cleanly and still did nothing, so the NetworkValue rewrite
was not the whole story. Rather than keep guessing at which link in the
chain is dead, add indicator icons bound to the internal signals.

An indicator draws while its toggle is off, so one glance at a radiator
now separates the cases that were previously indistinguishable:

  wrench absent   -> the AddBase never merged; nothing in the mod runs
  thermal missile -> no thermal-ammo signal arriving
  resource        -> no hold signal arriving from a battery

Tests check that every added indicator binds to a component that exists
and to a sprite that exists in the indicators atlas.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011oLWY1G6S8U35bi2FxVWni
This commit is contained in:
2026-08-28 23:46:22 +02:00
co-authored by Claude Opus 5
parent 3ad03d7964
commit e64b50c2be
4 changed files with 120 additions and 2 deletions
+46 -1
View File
@@ -16,7 +16,7 @@
ID = ganter.auto_radiator
Name = "Auto Radiator"
Version = 1.1.0
Version = 1.2.0
CompatibleGameVersions = ["0.30.4c", "0.30.4"]
ModifiesGameplay = true
Author = "Tobias Ganter"
@@ -118,4 +118,49 @@ Actions
Toggle = AutoPowerToggle
}
}
// --- Diagnostic indicators -------------------------------------------
//
// An indicator icon is drawn while its toggle is OFF. These three make the
// radiator report its own internal state, so a radiator that is not
// behaving can be read directly instead of guessed at:
//
// wrench icon always visible -> these components merged onto the part
// absent -> the AddBase did not take effect
// thermal missile visible -> no thermal-ammo signal is arriving
// resource icon visible -> no hold signal is arriving from a battery
//
// A working setup on a ship with a thermal launcher and a battery below the
// vent ceiling shows the wrench alone.
{
Action = AddMany
AddTo = "<ships/terran/radiator/radiator.rules>/Part/Components/Indicators/Indicators"
ManyToAdd
[
{
Toggle = AutoRad_AlwaysOff
AtlasSprite
{
File = &/INDICATORS/MissingComponent
Size = [1, 1]
}
}
{
Toggle = AutoRad_ThermalAmmoInUse
AtlasSprite
{
File = &/INDICATORS/NoThermalMissiles
Size = [1, 1]
}
}
{
Toggle = AutoRad_IsHolding
AtlasSprite
{
File = &/INDICATORS/NoResource
Size = [1, 1]
}
}
]
}
]