pub struct BoardDisplay {
pub board: [i8; 24],
pub bar: (u8, u8),
pub off: (u8, u8),
pub dice: (u8, u8),
}Expand description
Represents the Backgammon board for graphical representation only.
Fields§
§board: [i8; 24]The board is represented as an array of 24 fields, each of which can hold 0 or more checkers. Positive amounts represent checkers of player 0, negative amounts represent checkers of player 1.
bar: (u8, u8)The bar for both players.
off: (u8, u8)The off for both players.
dice: (u8, u8)Dice thrown.
Trait Implementations§
Source§impl Debug for BoardDisplay
impl Debug for BoardDisplay
Source§impl Display for BoardDisplay
impl Display for BoardDisplay
Source§impl PartialEq for BoardDisplay
impl PartialEq for BoardDisplay
impl StructuralPartialEq for BoardDisplay
Auto Trait Implementations§
impl Freeze for BoardDisplay
impl RefUnwindSafe for BoardDisplay
impl Send for BoardDisplay
impl Sync for BoardDisplay
impl Unpin for BoardDisplay
impl UnsafeUnpin for BoardDisplay
impl UnwindSafe for BoardDisplay
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