pub struct GameState {
pub turn: i8,
pub round: i32,
pub t1: f32,
pub t2: f32,
pub board: [[i8; 8]; 8],
}Fields§
§turn: i8§round: i32§t1: f32§t2: f32§board: [[i8; 8]; 8]Implementations§
Source§impl GameState
impl GameState
pub fn get_initial_state() -> Self
pub fn print_board(&self)
pub fn get_valid_moves(&self, player_num: i8) -> Vec<Position>
pub fn get_state_after_move( &self, position: Position, player_num: i8, ) -> GameState
Trait Implementations§
Auto Trait Implementations§
impl Freeze for GameState
impl RefUnwindSafe for GameState
impl Send for GameState
impl Sync for GameState
impl Unpin for GameState
impl UnwindSafe for GameState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more