agario-client.js
function(client, packet) {
            var teams_count  = packet.readUInt32LE();
            var teams_scores = [];

            for (var i=0;i<teams_count;++i) {
                teams_scores.push(packet.readFloat32LE());
            }

            if(JSON.stringify(client.teams_scores) == JSON.stringify(teams_scores)) return;
            var old_scores = client.teams_scores;

            if(client.debug >= 3)
                client.log('teams scores update: ' + JSON.stringify(teams_scores));

            client.teams_scores = teams_scores;

            client.emitEvent('teamsScoresUpdate', old_scores, teams_scores);
        }
function(client, packet) {
            var teams_count  = packet.readUInt32LE();
            var teams_scores = [];

            for (var i=0;i<teams_count;++i) {
                teams_scores.push(packet.readFloat32LE());
            }

            if(JSON.stringify(client.teams_scores) == JSON.stringify(teams_scores)) return;
            var old_scores = client.teams_scores;

            if(client.debug >= 3)
                client.log('teams scores update: ' + JSON.stringify(teams_scores));

            client.teams_scores = teams_scores;

            client.emitEvent('teamsScoresUpdate', old_scores, teams_scores);
        }
function ( client , packet ) { var teams_count = packet . readUInt32LE ( ) ; var teams_scores = [ ] ; for ( var i = 0 ; i < teams_count ; ++ i ) { teams_scores . push ( packet . readFloat32LE ( ) ) ; } if ( JSON . stringify ( client . teams_scores ) == JSON . stringify ( teams_scores ) ) return ; var old_scores = client . teams_scores ; if ( client . debug >= 3 ) client . log ( 'teams scores update: ' + JSON . stringify ( teams_scores ) ) ; client . teams_scores = teams_scores ; client . emitEvent ( 'teamsScoresUpdate' , old_scores , teams_scores ) ; }
teams scored update in teams mode
teams scored update in teams mode