Files
rttt/player/mod.rs
2026-01-04 17:45:57 +03:00

11 lines
346 B
Rust

mod human;
use crate::game::{Board, Cell, Move};
pub use human::PlayerConsole;
pub trait Player {
fn start_new_game(&mut self, p: Cell) -> Result<(), Box<dyn std::error::Error>>;
fn request_move(&self, b: &Board) -> Result<Move, Box<dyn std::error::Error>>;
fn message(&self, msg: &str) -> Result<(), Box<dyn std::error::Error>>;
}