From d6768c0fa987242c7a1b24c4fba2119664e4657d Mon Sep 17 00:00:00 2001 From: Andres Date: Sat, 3 May 2025 00:54:01 +0200 Subject: [PATCH] add new events to log parser --- src/app/(home)/log-parser/page.tsx | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/app/(home)/log-parser/page.tsx b/src/app/(home)/log-parser/page.tsx index 6dfb1a5..556481c 100644 --- a/src/app/(home)/log-parser/page.tsx +++ b/src/app/(home)/log-parser/page.tsx @@ -315,6 +315,20 @@ export default function LogParser() { type: 'event', }) } + } else if (line.includes('boughtCardFromShop')) { + const match = line.match(/card:([^,\n]+)/i) + if (match) { + const raw = match[1] ? match[1].trim() : '' + const clean = raw.replace(/^(c_mp_|j_mp_)/, '') + lines.push({ text: `Bought ${clean}`, type: 'event' }) + } + } else if (line.includes('rerollShop')) { + const match = line.match(/cost:([^,\n]+)/i) + if (match) { + const cost = match[1] ? match[1].trim() : '' + + lines.push({ text: `Reroll for $${cost}`, type: 'event' }) + } } else if (lineLower.includes('usedcard')) { const match = line.match(/card:([^,\n]+)/i) if (match) {