add new events to log parser

This commit is contained in:
2025-05-03 00:54:01 +02:00
parent 67ba549d09
commit d6768c0fa9

View File

@@ -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) {