Skip to content

Commit bda9c0d

Browse files
committed
Integrate upstream PR ottomated#288.
1 parent b9d0509 commit bda9c0d

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

src/renderer/Voice.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,15 @@ function calculateVoiceAudio(
101101
panPos[0] = Math.min(999, Math.max(-999, panPos[0]));
102102
panPos[1] = Math.min(999, Math.max(-999, panPos[1]));
103103
if (other.inVent) {
104-
gain.gain.value = 0;
105-
return;
104+
if (me.inVent) {
105+
gain.gain.value = 1;
106+
pan.positionX.setValueAtTime(panPos[0], audioContext.currentTime);
107+
pan.positionY.setValueAtTime(panPos[1], audioContext.currentTime);
108+
return;
109+
} else {
110+
gain.gain.value = 0;
111+
return;
112+
}
106113
}
107114
if (me.isDead && other.isDead) {
108115
gain.gain.value = 1;

0 commit comments

Comments
 (0)