words-game 0.1.0

Spelling game implementation
Documentation
1
2
3
4
5
6
7
8
9
use words_game::{Game, Tile};

pub fn stub_current_player_hand(game: &mut Game, hand: &str) {
    let current_player = game.get_current_player();

    assert_eq!(hand.len(), current_player.hand.len());

    current_player.hand = hand.chars().map(|c| Tile::from(c)).collect();
}