summaryrefslogtreecommitdiff
path: root/scene/2d/audio_stream_player_2d.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/2d/audio_stream_player_2d.cpp')
-rw-r--r--scene/2d/audio_stream_player_2d.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/2d/audio_stream_player_2d.cpp b/scene/2d/audio_stream_player_2d.cpp
index eaab58c4ae..94d22111ea 100644
--- a/scene/2d/audio_stream_player_2d.cpp
+++ b/scene/2d/audio_stream_player_2d.cpp
@@ -69,7 +69,7 @@ void AudioStreamPlayer2D::_notification(int p_what) {
if (setplay.get() >= 0 && stream.is_valid()) {
active.set();
- Ref<AudioStreamPlayback> new_playback = stream->instance_playback();
+ Ref<AudioStreamPlayback> new_playback = stream->instantiate_playback();
ERR_FAIL_COND_MSG(new_playback.is_null(), "Failed to instantiate playback.");
AudioServer::get_singleton()->start_playback_stream(new_playback, _get_actual_bus(), volume_vector, setplay.get(), pitch_scale);
stream_playbacks.push_back(new_playback);