pitch*speed );
_fx->set_velocity( velocity );
}
- else if (_aimodel)
+ else if ((_aimodel)&&(fgGetBool("/sim/sound/aimodels/enabled",false)))
{
string fxpath = _aimodel->get_sound_path();
if (fxpath != "")
props->setBoolValue("/sim/controls/radar/", true);
+ // drop reference to sound effects now
+ _fx = 0;
}
double FGAIBase::UpdateRadar(FGAIManager* manager) {