From 7d22e2e2e540563246dfd3d2ba778969ef62118f Mon Sep 17 00:00:00 2001 From: stm <14291421+stephanmeesters@users.noreply.github.com> Date: Fri, 13 Feb 2026 17:53:57 +0100 Subject: [PATCH 1/2] bugfix(audio): Fix particle cannon being inaudible after saveload --- .../Object/Update/ParticleUplinkCannonUpdate.cpp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp b/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp index e360f8842ff..3bdd3421e84 100644 --- a/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp +++ b/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp @@ -1559,4 +1559,20 @@ void ParticleUplinkCannonUpdate::loadPostProcess( void ) } } + // TheSuperHackers @info stephanmeesters 13/02/2026 + // Fix issue where sound from the particle cannon is not audible after saveload + if( m_status == STATUS_FIRING || m_status == STATUS_POSTFIRE || m_status == STATUS_PACKING ) + { + if( m_firingToIdleSound.getEventName().isNotEmpty() ) + { + m_firingToIdleSound.setObjectID( getObject()->getID() ); + m_firingToIdleSound.setPlayingHandle( TheAudio->addAudioEvent( &m_firingToIdleSound ) ); + } + if( m_orbitToTargetBeamID != INVALID_DRAWABLE_ID && m_annihilationSound.getEventName().isNotEmpty() ) + { + m_annihilationSound.setDrawableID( m_orbitToTargetBeamID ); + m_annihilationSound.setPlayingHandle( TheAudio->addAudioEvent( &m_annihilationSound ) ); + } + } + } From 169ce11104f32b987391f2175b63682de1048911 Mon Sep 17 00:00:00 2001 From: stm <14291421+stephanmeesters@users.noreply.github.com> Date: Sat, 14 Feb 2026 11:30:07 +0100 Subject: [PATCH 2/2] Reevaluate code based on table of results, add code for some more previously inaudible sounds --- .../Update/ParticleUplinkCannonUpdate.cpp | 24 +++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp b/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp index 3bdd3421e84..04765320654 100644 --- a/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp +++ b/GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/ParticleUplinkCannonUpdate.cpp @@ -1559,20 +1559,36 @@ void ParticleUplinkCannonUpdate::loadPostProcess( void ) } } - // TheSuperHackers @info stephanmeesters 13/02/2026 - // Fix issue where sound from the particle cannon is not audible after saveload - if( m_status == STATUS_FIRING || m_status == STATUS_POSTFIRE || m_status == STATUS_PACKING ) + // TheSuperHackers @bugfix stephanmeesters 13/02/2026 + // Fix issue where particle cannon sounds are not audible after saveload. + + if( (m_status == STATUS_CHARGING || m_status == STATUS_PREPARING || m_status == STATUS_ALMOST_READY) && + m_powerupSound.getEventName().isNotEmpty() ) + { + m_powerupSound.setObjectID( getObject()->getID() ); + m_powerupSound.setPlayingHandle( TheAudio->addAudioEvent( &m_powerupSound ) ); + } + + if( (m_status == STATUS_PREPARING || m_status == STATUS_ALMOST_READY || m_status == STATUS_READY_TO_FIRE || m_status == STATUS_PREFIRE) && + m_unpackToReadySound.getEventName().isNotEmpty() ) + { + m_unpackToReadySound.setObjectID( getObject()->getID() ); + m_unpackToReadySound.setPlayingHandle( TheAudio->addAudioEvent( &m_unpackToReadySound ) ); + } + + if ( m_status == STATUS_FIRING || m_status == STATUS_POSTFIRE || + (m_status == STATUS_PACKING && (m_laserStatus == LASERSTATUS_DECAYING || m_laserStatus == LASERSTATUS_DEAD)) ) { if( m_firingToIdleSound.getEventName().isNotEmpty() ) { m_firingToIdleSound.setObjectID( getObject()->getID() ); m_firingToIdleSound.setPlayingHandle( TheAudio->addAudioEvent( &m_firingToIdleSound ) ); } + if( m_orbitToTargetBeamID != INVALID_DRAWABLE_ID && m_annihilationSound.getEventName().isNotEmpty() ) { m_annihilationSound.setDrawableID( m_orbitToTargetBeamID ); m_annihilationSound.setPlayingHandle( TheAudio->addAudioEvent( &m_annihilationSound ) ); } } - }