浏览代码

Fix AudioPlayer.play() bug when music always starts from 0 pos

NNesh 8 年之前
父节点
当前提交
0edc3d7208
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      modules/stb_vorbis/audio_stream_ogg_vorbis.cpp

+ 1 - 1
modules/stb_vorbis/audio_stream_ogg_vorbis.cpp

@@ -66,8 +66,8 @@ float AudioStreamPlaybackOGGVorbis::get_stream_sampling_rate() {
 
 void AudioStreamPlaybackOGGVorbis::start(float p_from_pos) {
 
-	seek_pos(p_from_pos);
 	active = true;
+	seek_pos(p_from_pos);
 	loops = 0;
 	_begin_resample();
 }