From cba960240332b0e5b9b8f0f4845738c2912fcbb9 Mon Sep 17 00:00:00 2001 From: lee Date: Tue, 31 Dec 2024 16:08:20 +0900 Subject: [PATCH 1/2] =?UTF-8?q?=ED=98=84=EC=9E=AC=20=EB=B9=A0=EB=A5=B4?= =?UTF-8?q?=EA=B8=B0=EB=A5=BC=20=EA=B8=B0=EC=A4=80=EC=9C=BC=EB=A1=9C=20?= =?UTF-8?q?=EC=9E=AC=EC=83=9D=EC=8B=9C=EA=B0=84=EC=9D=84=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit as-is 재생하고 기다리기 블럭의 재생시간 = 오디오 파일의 재생시간 to-be 재생하고 기다리기 블럭의 재생시간 = 오디오 파일의 재생시간 / 현재 빠르기 --- src/playground/block_entry.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/playground/block_entry.js b/src/playground/block_entry.js index 2fc1f5f59c..9358b8d563 100644 --- a/src/playground/block_entry.js +++ b/src/playground/block_entry.js @@ -2709,11 +2709,12 @@ function getBlocks() { const sounds = sprite.parent.sounds; const isExist = Entry.isExist(soundId, 'id', sounds); if (isExist) { + const duration = Math.floor(sound.duration * 1000 / Entry.playbackRateValue); const instance = Entry.Utils.playSound(soundId); Entry.Utils.addSoundInstances(instance); setTimeout(() => { script.playState = 0; - }, sound.duration * 1000); + }, duration); } return script; } else if (script.playState === 1) { From 2764f604541558c3b2c2aa18421768767363ddff Mon Sep 17 00:00:00 2001 From: leunge Date: Tue, 7 Jan 2025 11:55:06 +0900 Subject: [PATCH 2/2] Update src/playground/block_entry.js Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- src/playground/block_entry.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/playground/block_entry.js b/src/playground/block_entry.js index 9358b8d563..dd62a9a4ad 100644 --- a/src/playground/block_entry.js +++ b/src/playground/block_entry.js @@ -2709,7 +2709,9 @@ function getBlocks() { const sounds = sprite.parent.sounds; const isExist = Entry.isExist(soundId, 'id', sounds); if (isExist) { - const duration = Math.floor(sound.duration * 1000 / Entry.playbackRateValue); + const duration = Math.floor( + (sound.duration * 1000) / Entry.playbackRateValue + ); const instance = Entry.Utils.playSound(soundId); Entry.Utils.addSoundInstances(instance); setTimeout(() => {