<commit_before>import Whos from './Whos.js';

class Match
{

    constructor(playerA, playerB)
    {
        var deck = _(Whos).cloneDeep().shuffle().value();
        this.a = {
            board: new Board(_(Whos).cloneDeep().shuffle().value()),
            player: playerA,
            who: deck.pop(),
        };
        this.b = {
            board: new Board(_(Whos).cloneDeep().shuffle().value()),
            player: playerB,
            who: deck.pop(),
        };
        this.current = this.a;
    }

    run()
    {
        while (true) {
            var board = this.current.board;
            var player = this.current.player;
            var other = this.notCurrent();
            var otherInfo = {
                name: other.name,
                remaining: other.board.remaining.length,
                rejected: other.board.rejected.length,
            };
            var strategy = new player.class();
            strategy.run(_.cloneDeep(board), otherInfo);
        }
    }

    switch() 
    {
        this.current = this.notCurrent();
    }<commit_msg>more like this<commit_after>import Whos from './Whos.js';

class Match
{

    constructor(playerA, playerB)
    {
        var deck = _(Whos).cloneDeep().shuffle().value();
        this.a = {
            board: new Board(_(Whos).cloneDeep().shuffle().value()),
            player: playerA,
            who: deck.pop(),
        };
        this.b = {
            board: new Board(_(Whos).cloneDeep().shuffle().value()),
            player: playerB,
            who: deck.pop(),
        };
        this.current = this.a;
    }

    run()
    {
        while (true) {
            var board = this.current.board;
            var player = this.current.player;
            var other = this.notCurrent();
            var otherInfo = {
                name: other.name,
                remaining: other.board.remaining.length,
                rejected: other.board.rejected.length,
            };
            var strategy = new player.class();
            var move = strategy.move(_.cloneDeep(board), otherInfo);
        }
    }

    switch() 
    {
        this.current = this.notCurrent();
    }
{'fraction_non_alphanumeric': 0.13651087459509487, 'fraction_numerical': 0.0, 'mean_word_length': 1.4736842105263157, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6860103', 'n_tokens_mistral': 614, 'n_tokens_neox': 603, 'n_words': 120}