From bc4ebf37286d928c2b9d891cc9c9c54565642cf8 Mon Sep 17 00:00:00 2001 From: nucular Date: Tue, 28 Oct 2014 16:43:15 +0100 Subject: [PATCH] Reset parameters to default before loading from a file --- sfxr.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sfxr.lua b/sfxr.lua index 97eb957..415a2d6 100644 --- a/sfxr.lua +++ b/sfxr.lua @@ -1085,6 +1085,7 @@ function sfxr.Sound:load(f) return version end + self:resetParameters() -- merge the loaded table into the own mergetables(self, params) @@ -1165,6 +1166,8 @@ function sfxr.Sound:loadBinary(f) f:close() end + self:resetParameters() + local off = 1 local function readFloat()