Fix location of clip start call.

This commit is contained in:
Chandler Cox
2025-08-01 15:15:54 -05:00
parent 0e3a22faa0
commit 6f15ef7690

View File

@@ -395,15 +395,15 @@ void AudioSource::Update()
AudioBackend::Source::VelocityChanged(SourceID, _velocity);
}
if (Math::NearEqual(GetTime(), _startTime) && _isActuallyPlayingSth && _startingToPlay)
ClipStarted();
// Reset starting to play value once time is greater than zero
if (_startingToPlay && GetTime() > 0.0f)
{
_startingToPlay = false;
}
if (Math::NearEqual(GetTime(), _startTime) && _isActuallyPlayingSth && _startingToPlay)
ClipStarted();
if (!UseStreaming() && Math::NearEqual(GetTime(), 0.0f) && _isActuallyPlayingSth && !_startingToPlay)
{
int32 queuedBuffers;