diff --git a/src/converter.js b/src/converter.js index cf0a377..f949151 100644 --- a/src/converter.js +++ b/src/converter.js @@ -144,18 +144,17 @@ class Converter { var removedSamples = 0; var sampleBytesSaved = 0; - var instrumentMap = []; var currentInstrument = 1; for (var i = 0; i < mod.instruments.length; i++) { - if (mod.instruments[i].length > 0) { - if (!usedInstruments.has(mod.instruments[i].number)) { + if (!usedInstruments.has(mod.instruments[i].number)) { + if (mod.instruments[i].length > 0) { sampleBytesSaved += mod.killInstrument(mod.instruments[i].number); removedSamples++; - } else { - instrumentMap[i + 1] = currentInstrument++; - } + } + } else { + instrumentMap[i + 1] = currentInstrument++; } } diff --git a/static/index.html b/static/index.html index 1ac7ce8..a393a81 100644 --- a/static/index.html +++ b/static/index.html @@ -17,7 +17,7 @@ / /_/ _/ / / /_/ / / \_/ \______/\_/\_/ \____/ - -= RETROCONVERTER v1.0.0 =- + -= RETROCONVERT v1.0.1 =- © 2020-2021 JUiCE / iNSANE ^ Reality