Skip to content

Commit

Permalink
adding empty aggreagte/logging methods for index.ts for loop to run
Browse files Browse the repository at this point in the history
  • Loading branch information
bennyrubanov committed Nov 17, 2023
1 parent d7a641a commit effcf3e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ async function gameIterator(path) {
// with array creation
const historyGenerator = cjsmin.historyGeneratorArr(moves);
metric.processGame(Array.from(historyGenerator), metadata);
// metric.aggregate();
// metric.logResults();
metric.aggregate();
metric.logResults();
}
}
kdRatioMetric.aggregate();
Expand Down
8 changes: 8 additions & 0 deletions src/metrics/captures.ts
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,14 @@ export class MateAndAssistMetric implements Metric {
};
}

aggregate() {

}

logResults() {

}

// One edge case currently unaccounted for is when pieces "share" a mate, or check. This can be at most 2 due to discovery
// checks (currently we disregard this by just saying the last piece to move is the "mating piece")
processGame(game: { move: PrettyMove; board: Piece[] }[]) {
Expand Down
4 changes: 4 additions & 0 deletions src/metrics/moves.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ export class GameWithMostMovesMetric implements Metric {
}
}

aggregate() {

}

logResults(): void {
console.log('MOVES FACTS:');
console.log(`The game with the most moves played: ${this.link}`);
Expand Down

0 comments on commit effcf3e

Please sign in to comment.