Skip to content

Instantly share code, notes, and snippets.

@dzaima
Last active March 16, 2018 19:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dzaima/d339324337cc4bf65659e7bf842c2311 to your computer and use it in GitHub Desktop.
Save dzaima/d339324337cc4bf65659e7bf842c2311 to your computer and use it in GitHub Desktop.
rawData = ProgressReport[1][0].teams.map(
(c, id) => ({
id: c.id,
name: document.querySelector(`.team-${c.id} .player`).innerHTML,
games: c.rawFoodGotten.map(cg => ({
food: cg.food,
workers: cg.workers,
score: cg.score
}))
})
);
foodScores = rawData.map(c=> [c.name, c.games.map(c=>c.food)])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment