diff --git a/Zframework/sfx.lua b/Zframework/sfx.lua index a1f90819..8f5c5c20 100644 --- a/Zframework/sfx.lua +++ b/Zframework/sfx.lua @@ -1,5 +1,6 @@ local type,rem=type,table.remove local int,rnd=math.floor,math.random +local interval=MATH.interval local sfxList={} local packSetting={} @@ -140,7 +141,7 @@ local function _play(name,vol,pos,pitch) S=S[n]--AU_SRC if S:getChannelCount()==1 then if pos then - pos=pos*stereo + pos=interval(pos,-1,1)*stereo S:setPosition(pos,1-pos^2,0) else S:setPosition(0,0,0)