pub trait FigureTrait {
// Required methods
fn symbol(self) -> &'static str;
fn base_figure(self) -> Figure;
fn lancer_direction(self) -> usize;
}
Expand description
FigureTrait adds methods to Figure
Required Methods§
Sourcefn base_figure(self) -> Figure
fn base_figure(self) -> Figure
returns the base figure of the figure, same as figure except for lancers, where it is LANCER
Sourcefn lancer_direction(self) -> usize
fn lancer_direction(self) -> usize
return the lancer direction of the figure provided that it is a lancer