diff --git a/Capy64/Runtime/Libraries/Audio.cs b/Capy64/Runtime/Libraries/Audio.cs index 5180126..d64d30e 100644 --- a/Capy64/Runtime/Libraries/Audio.cs +++ b/Capy64/Runtime/Libraries/Audio.cs @@ -142,7 +142,10 @@ public class Audio : IPlugin var freq = L.CheckNumber(1); var time = L.OptNumber(2, 1); var volume = L.OptNumber(3, 1); - Math.Clamp(volume, 0, 1); + + + + volume = Math.Clamp(volume, 0, 1); var buffer = Core.Audio.GenerateSquareWave(freq, time, volume);