var NHLScore = {
	league: 'NHL',
	updateURL: 'http://live.nhle.com/GameData/RegularSeasonScoreboardv3.jsonp',
	getGameArray: function(rawData) {
		rawData = rawData.replace('loadScoreboard(','');
		rawData = rawData.substring(0,(rawData.length-2));
		return JSON.parse(rawData).games;
	},
	parseRawGame: function(rawGame) {
		var gameDate; //make date from rawGame data
		var gameState; //make state from rawGame
		this.gameId = rawGame.id;
		this.state = gameState;
		this.date = gameDate;
		this.gameTime = rawGame.tsc;
		this.awayTeam = rawGame.atn;
		this.awayScore = rawGame.ats;
		this.homeTeam = rawGame.htn;
		this.homeScore = rawGame.hts;
	},
	makeGameLink: function() {
		var linkStub = 'http://www.nhl.com/gamecenter/en/icetracker?id=';
		return linkStub + this.gameId;
	}
};

module.exports = NHLScore;
@@ -392,35 +392,465 @@
 tate
-; //make state from rawGame
+ = '';%0D%0A%09%09switch (rawGame.gs) %7B%0D%0A%09%09%09case '1':%0D%0A%09%09%09%09gameState = 'scheduled';%0D%0A%09%09%09%09break;%0D%0A%09%09%09case '3':%0D%0A%09%09%09%09if (rawGame.ts.indexOf('END') !== -1) %7B%0D%0A%09%09%09%09%09gameState = 'intermission';%0D%0A%09%09%09%09%7D else %7B%0D%0A%09%09%09%09%09gameState = 'progress';%0D%0A%09%09%09%09%7D%0D%0A%09%09%09%09break;%0D%0A%09%09%09case '4':%0D%0A%09%09%09%09if (rawGame.ts.indexOf('SHOOTOUT') !== -1) %7B%0D%0A%09%09%09%09%09gameState = 'shootout';%0D%0A%09%09%09%09%7D else %7B%0D%0A%09%09%09%09%09gameState = 'overtime';%0D%0A%09%09%09%09%7D%0D%0A%09%09%09%09break;%0D%0A%09%09%09case '5':%0D%0A%09%09%09%09gameState = 'ended';%0D%0A%09%09%09%09break;%0D%0A%09%09%7D
 %0D%0A%09%09

parse nhl game state