From 143f8772036561176c5db2957d4c428e2d8596b3 Mon Sep 17 00:00:00 2001 From: Florent Castelli Date: Tue, 8 Aug 2023 00:58:08 +0200 Subject: [PATCH] Add option to generate a single macro with all the steps --- app/js/components/macros.js | 4 ++-- app/modals/options.html | 7 +++++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/app/js/components/macros.js b/app/js/components/macros.js index e2195019b..2e7edb0b9 100644 --- a/app/js/components/macros.js +++ b/app/js/components/macros.js @@ -138,7 +138,7 @@ macroTime += line.time; macroLineCount += 1; - if (macroLineCount === MAX_LINES - 1) { + if (!options.singleMacro && macroLineCount === MAX_LINES - 1) { if (lines.length - (j + 1) > 1) { if(options.useNextMacro) { @@ -164,7 +164,7 @@ } if (macroLineCount > 0) { - if (macroLineCount < MAX_LINES) { + if (options.singleMacro || macroLineCount < MAX_LINES) { macroString += '/echo Macro #' + macroIndex + ' complete ' + soundEffect(options.finishSoundEffect, options.stepSoundEnabled) + '\n'; } macroList.push({text: macroString, time: macroTime}); diff --git a/app/modals/options.html b/app/modals/options.html index aa52e2d94..a96eae459 100644 --- a/app/modals/options.html +++ b/app/modals/options.html @@ -289,6 +289,13 @@

{{ 'OPTIONS' | translate }}

{{ 'MACRO_NEXTMACRO' | translate }} + +
+ +