Merge pull request #238 from cetteup/master

Fix teamOffByOne condition for Battlefield 1942
This commit is contained in:
Michael Morrison 2022-02-05 19:25:09 -06:00 committed by GitHub
commit 91d4db40e0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -46,7 +46,7 @@ class Gamespy1 extends Core {
if ('maxplayers' in data) state.maxplayers = parseInt(data.maxplayers);
if ('hostport' in data) state.gamePort = parseInt(data.hostport);
const teamOffByOne = data.gameid === 'bf1942';
const teamOffByOne = data.gamename === 'bfield1942';
const playersById = {};
const teamNamesById = {};
for (const ident of Object.keys(data)) {