Audio, Combat Feedback, and Visual Polish Update
This branch focused heavily on improving how Stellar Warfare sounds and feels during larger battles. The main goal was to keep the existing soundscape intact, but make it more stable, less distorted, and better suited for dense combat where many weapons can fire at once.
Audio Overhaul
- Integrated FMOD into the project for combat audio, voice lines, general SFX, UI sounds, engine hums, music, and several special effects.
- Migrated many existing MP3-based sounds to WAV sources for FMOD playback.
- Added FMOD event limits for busy combat sounds so large battles no longer stack unlimited overlapping sounds.
- Combat sounds now prioritize closer/louder sounds instead of blindly keeping the oldest sound.
- Adjusted source headroom on hot sounds so they have more space before distortion.
- Updated plasma weapon audio to use the newer `plasma3.wav`.
- Removed unused old cannon impact sounds and cleaned up related FMOD references.
- Fixed flak audio so it behaves closer to the old soundscape and does not spam excessive sound triggers.
- Added flak detonation audio when flak expires/detonates after missing.
- Replaced the combat music source with the new `greg v2 line of sight constant combat.wav`.
Music Changes
- Retuned in-game music so calmer ambience is more common during normal gameplay.
- Removed `Against the dying light` from the normal in-game playlist.
- Added dynamic combat music behavior: nearby combat fades the background music down and brings in the combat track.
- Combat music reacts to nearby combat activity around the camera instead of using a simple global on/off switch.
- Added light music ducking support for important campaign voice-over playback.
Voice Line Fixes
- Routed ship voice lines and announcer lines through FMOD while preserving the existing voice volume logic.
- Fixed ship voice actor assignment so ships use their original intended voice sets again.
- Fixed supership voice routing, including Behemoth voice selection.
- Adjusted command voice behavior so newer command feedback can replace older feedback instead of waiting too long.
- Reduced loudness of announcer/resource warning categories.
- Resource shortage warnings now rotate and respect shared cooldowns, so power/metal/population warnings no longer stack immediately on top of each other.
Combat Feel
- Added event-driven camera impact shake for visible nearby impacts.
- Camera shake now works for hull and shield impacts.
- Shake strength scales by damage and distance.
- Impacts near the focused unit/building can shake the camera up to a wider nearby range.
- Close visible impacts can also shake the camera when no focus target is active.
- The system is event-driven and does not scan every ship every frame.
Movement and Spawn Fixes
- Fixed supership spawn rally behavior so spawned superships no longer travel toward the map center by mistake.
- Superships now move to safer randomized positions near their intended spawn/rally point to reduce clustering.
- Stabilized ship movement around combat targets to reduce vibration/jitter from repeated target recalculation.
- Adjusted space-ballet movement so ships do not constantly repick tiny movement targets.
- Improved dodge behavior so ships do not overwrite active dodge destinations every check.
Engine Trails and Visual Cleanup
- Fixed overly bright enemy engine trails.
- Removed unwanted engine trail children from ship prefabs where appropriate.
- Engine trails now wait until ships have cleared spawn before appearing.
- Retuned trail widths by ship class:
- Small ships: 0.3
- Medium ships: 0.5
- Heavy ships: 0.8
- Superships: 1.0
- Harvesters and surveyors keep light-sized trails.
Tutorial and Interaction Fixes
- Improved Alt + Left Click tutorial behavior so it works on more target types, including asteroids, buildings, ships, and enemies.
- Kept camera shake optional through the existing game settings/global controls.
Under the Hood
- Added FMOD setup documentation for contributors.
- Added tooling for generating FMOD combat, voice, and legacy audio events.
- Added tuning scripts for FMOD event limits and voice policy.
- Updated project documentation explaining why combat audio limits exist and how they are tuned.
- Rebuilt FMOD runtime banks for the updated audio setup.
