16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-22 13:59:19 +02:00

fix another missing sound crash

This commit is contained in:
milek7
2017-08-19 13:09:14 +02:00
parent eaddd4b91a
commit 3bbef8bde5

View File

@@ -3736,7 +3736,7 @@ void TDynamicObject::RenderSounds()
} }
enginevolume = (enginevolume + vol) * 0.5; enginevolume = (enginevolume + vol) * 0.5;
if( enginevolume < 0.01 ) { if( enginevolume < 0.01 ) {
rsSilnik->stop(); if (rsSilnik) rsSilnik->stop();
} }
if ( (( MoverParameters->EngineType == ElectricSeriesMotor ) if ( (( MoverParameters->EngineType == ElectricSeriesMotor )
|| ( MoverParameters->EngineType == ElectricInductionMotor )) || ( MoverParameters->EngineType == ElectricInductionMotor ))