Platform
Platform: Paper 1.21.10
PlasmoVoice Version: 2.1.6/2.1.8
Description
When resuming the AudioSender via the resume method the audio has an extrem delay, depending on the already elapsed playtime and pause time.
After looking at the source code, I think the issue is, that the startTime is reset to 0 (or the current System.nanoTime() after resuming) without respecting the value of sequenceNumber which is still at the same position/index. This causes the waitTime to became very high in the first iteration after the pause just to "match" the current index in the audio to the expected time.
A fix would be to recalculate the startTime after the resume or save the total pause time and combine it with the waitTime.
Platform
Platform: Paper 1.21.10
PlasmoVoice Version: 2.1.6/2.1.8
Description
When resuming the AudioSender via the
resumemethod the audio has an extrem delay, depending on the already elapsed playtime and pause time.After looking at the source code, I think the issue is, that the
startTimeis reset to0(or the currentSystem.nanoTime()after resuming) without respecting the value ofsequenceNumberwhich is still at the same position/index. This causes thewaitTimeto became very high in the first iteration after the pause just to "match" the current index in the audio to the expected time.A fix would be to recalculate the
startTimeafter the resume or save the total pause time and combine it with thewaitTime.