[−][src]Struct worldgen::world::tile::Tile
Objects to generate in the world based on given constraints
Implementations
impl<T: Clone> Tile<T>
[src]
pub fn new(value: T) -> Tile<T>
[src]
Construct a new tile represented by the given object.
pub fn when(self, constraint: Constraint) -> Tile<T>
[src]
Adds a constraint to the tile.
pub fn value(&self) -> T
[src]
Returns the value this tile is represented by.
pub fn satisfied_by(
&self,
x: i64,
y: i64,
size: Size,
chunk_x: i64,
chunk_y: i64,
nms: &mut HashMap<u64, Vec<Vec<f64>>>
) -> bool
[src]
&self,
x: i64,
y: i64,
size: Size,
chunk_x: i64,
chunk_y: i64,
nms: &mut HashMap<u64, Vec<Vec<f64>>>
) -> bool
Returns true if the given value would satisfy all of this tile's constraints.
Auto Trait Implementations
impl<T> !RefUnwindSafe for Tile<T>
impl<T> !Send for Tile<T>
impl<T> !Sync for Tile<T>
impl<T> Unpin for Tile<T> where
T: Unpin,
T: Unpin,
impl<T> !UnwindSafe for Tile<T>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,