From a777b2651715597782ba362cfa2afe331a8dfff1 Mon Sep 17 00:00:00 2001 From: AnimeDL Date: Mon, 25 Mar 2024 22:59:49 -0700 Subject: [PATCH] vtt2ass: Reverse all subtitles This should (hopefully) make it line up with how subtitles are displayed on Hidive. --- modules/module.vtt2ass.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/modules/module.vtt2ass.ts b/modules/module.vtt2ass.ts index 7199a8c..b1b4156 100644 --- a/modules/module.vtt2ass.ts +++ b/modules/module.vtt2ass.ts @@ -299,14 +299,18 @@ function convert(css: Css, vtt: Vtt[]) { events[x.type as keyof typeof events].pop(); const previousLinePop = events[x.type as keyof typeof events].pop(); events[x.type as keyof typeof events].push(previousLinePop + '\\N'+x.text); - } else if ((currentStart - previousStart) <= 3) { + }/* else if ((currentStart - previousStart) <= 3) { const currentLinePop = events[x.type as keyof typeof events].pop(); const previousLinePop = events[previousLine.type as keyof typeof events].pop(); events[x.type as keyof typeof events].push(currentLinePop as string, previousLinePop as string); - } + }*/ } previousLine = x; } + events.subtitle.reverse(); + events.caption.reverse(); + events.capt_pos.reverse(); + events.song_cap.reverse(); if (events.subtitle.length > 0) { ass = ass.concat( //`Comment: 0,0:00:00.00,0:00:00.00,${defaultStyleName},,0,0,0,,** Subtitles **`,