diff --git a/CHANGELOG.md b/CHANGELOG.md index 3585045..b6d6e32 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ ## To Be Released... ## 5.X.Y +* Fix: detect BFBC2 Vietnam DLC as BFBC2 (By @cetteup #713) ## 5.3.1 * Fix: HTTP requests would end up making more retries than needed due to got's internal retry mechanism (#690, thanks @RattleSN4K3) diff --git a/protocols/battlefield.js b/protocols/battlefield.js index 697c2e3..4824f30 100644 --- a/protocols/battlefield.js +++ b/protocols/battlefield.js @@ -39,7 +39,8 @@ export default class battlefield extends Core { if (data.length) state.raw.uptime = parseInt(data.shift()) if (data.length) state.raw.roundtime = parseInt(data.shift()) - const isBadCompany2 = data[0] === 'BC2' + // If this is a Bad Company 2 server, the next field will indicate the "gameMod" followed by an unknown field + const isBadCompany2 = data[0] === 'BC2' || data[0] === 'VIETNAM' if (isBadCompany2) { if (data.length) data.shift() if (data.length) data.shift()