Return setseek position if one exists in get_playback_position.
This commit is contained in:
parent
8fa92c70ea
commit
15b8480b2c
@ -342,6 +342,9 @@ bool AudioStreamPlayer2D::is_playing() const {
|
||||
|
||||
float AudioStreamPlayer2D::get_playback_position() {
|
||||
if (stream_playback.is_valid()) {
|
||||
if (setseek >= 0.0) {
|
||||
return setseek;
|
||||
}
|
||||
return stream_playback->get_playback_position();
|
||||
}
|
||||
|
||||
|
@ -714,6 +714,9 @@ bool AudioStreamPlayer3D::is_playing() const {
|
||||
|
||||
float AudioStreamPlayer3D::get_playback_position() {
|
||||
if (stream_playback.is_valid()) {
|
||||
if (setseek >= 0.0) {
|
||||
return setseek;
|
||||
}
|
||||
return stream_playback->get_playback_position();
|
||||
}
|
||||
|
||||
|
@ -267,6 +267,9 @@ bool AudioStreamPlayer::is_playing() const {
|
||||
|
||||
float AudioStreamPlayer::get_playback_position() {
|
||||
if (stream_playback.is_valid()) {
|
||||
if (setseek >= 0.0) {
|
||||
return setseek;
|
||||
}
|
||||
return stream_playback->get_playback_position();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user