Access Parameters of a Sound Que?

For anyone that comes across this post looking for the c++ solution (as google brings you here as the first result for c++ SoundCue parameter)


Example… Setup an Audio Component and load the Sound Cue

 UAudioComponent* propellerAudioComponent;

 // Load our Sound Cue 
 static ConstructorHelpers::FObjectFinder<USoundCue> propellerCue(
     TEXT("'/Game/airplane-engine.airplane-engine'")
 );

 // create an Audio Component - this is how we control the SoundCue
 propellerAudioComponent = CreateDefaultSubobject<UAudioComponent>(
     TEXT("PropellerAudioComp")
 );

 // Attach our sound cue to the SoundComponent (outside the constructor)
 propellerAudioComponent->SetSound(propellerCue.Object;);

Set a parameter of the sound cue, and play it

 // Set a parameter named 'pitch' on the Sound Cue 
 propellerAudioComponent->SetFloatParameter(FName("pitch"), 0.8f);

 // Finally play the sound  (outside the constructor)
 propellerAudioComponent->Play();

For a longer explanation see my blog article: playing sounds from c++ using Sound Cues