Navigation
API > API/Runtime > API/Runtime/Engine
A sound actor that can be placed in a level
| Name | AAmbientSound |
| Type | class |
| Header File | /Engine/Source/Runtime/Engine/Classes/Sound/AmbientSound.h |
| Include Path | #include "Sound/AmbientSound.h" |
Syntax
UCLASS (AutoExpandCategories=Audio, ClassGroup=Sounds, HideCategories=(Collision, Input, Game),
ShowCategories=("Input|MouseInput", "Input|TouchInput", "Game|Damage"),
ComponentWrapperClass, MinimalAPI)
class AAmbientSound : public AActor
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → AActor → AAmbientSound
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
AAmbientSound
(
const FObjectInitializer& ObjectInitializer |
Sound/AmbientSound.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AudioComponent | TObjectPtr< class UAudioComponent > | Audio component that handles sound playing | Sound/AmbientSound.h |
|
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AdjustVolume
(
float AdjustVolumeDuration, |
Sound/AmbientSound.h |
|
|
void FadeIn
(
float FadeInDuration, |
BEGIN DEPRECATED (use component functions now in level script) | Sound/AmbientSound.h |
|
void FadeOut
(
float FadeOutDuration, |
Sound/AmbientSound.h |
|
|
UAudioComponent * GetAudioComponent() |
Returns AudioComponent subobject | Sound/AmbientSound.h | |
FString GetInternalSoundCueName() |
Sound/AmbientSound.h | ||
void Play
(
float StartTime |
Sound/AmbientSound.h |
|
|
void Stop() |
Sound/AmbientSound.h |
|
Overridden from AActor
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void CheckForErrors() |
Function that gets called from within Map_Check to allow this actor to check itself for any potential errors and register them with map check dialog. | Sound/AmbientSound.h | |
| Used by the "Sync to Content Browser" right-click menu option in the editor. | Sound/AmbientSound.h | ||
virtual void PostRegisterAllComponents () |
Called after all the components in the Components array are registered, called both in editor and during gameplay. | Sound/AmbientSound.h |