RealDocs

UGameplayStatics::SetBaseSoundMix

function Engine Blueprint Since 4.0
#include "Kismet/GameplayStatics.h"
Access: public Specifiers: staticUFUNCTIONBlueprintCallable

Description

Sets the active base sound mix for the audio engine, applying the EQ and volume/pitch adjustments defined in the mix asset globally. Only one base mix can be active at a time.

Caveats & Gotchas

  • Calling this replaces any previously set base mix immediately; there is no blend or fade transition unless the SoundMix asset has FadeIn time configured.
  • Passing nullptr clears the current base mix and restores default audio settings.
  • The base mix is separate from pushed sound mixes (PushSoundMixModifier); they stack on top of the base mix, so changing the base mix while modifiers are active can produce unexpected combined results.

Signature

static ENGINE_API void SetBaseSoundMix(const UObject* WorldContextObject, class USoundMix* InSoundMix)

Parameters

Name Type Description Default
WorldContextObject const UObject* Object used to obtain the world context.
InSoundMix class USoundMix* The sound mix asset to set as the active base mix.

Return Type

void

Example

Apply a music mix when entering a dungeon C++
void ADungeonZoneTrigger::OnPlayerEnter(AActor* Player)
{
	UGameplayStatics::SetBaseSoundMix(this, DungeonMix);
}

Version History

Introduced in: 4.0

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.