pub enum MapGenSize {
Number(f32),
Named(&'static str),
}Expand description
A floating point number specifying an amount.
For backwards compatibility, MapGenSizes can also be specified as a string, which will be converted to a number (when queried, a number will always be returned).
The map generation algorithm officially supports the range of values the in-game map generation screen shows (specifically 0 and values from 1/6 to 6). Values outside this range are not guaranteed to work as expected.
Map generation size: a number or a named preset string.
Variants§
Trait Implementations§
Source§impl Clone for MapGenSize
impl Clone for MapGenSize
Source§fn clone(&self) -> MapGenSize
fn clone(&self) -> MapGenSize
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for MapGenSize
Source§impl Debug for MapGenSize
impl Debug for MapGenSize
Source§impl Default for MapGenSize
impl Default for MapGenSize
Source§impl From<&'static str> for MapGenSize
impl From<&'static str> for MapGenSize
Source§impl From<MapGenSize> for LuaAny
impl From<MapGenSize> for LuaAny
Source§fn from(_: MapGenSize) -> Self
fn from(_: MapGenSize) -> Self
Converts to this type from the input type.
Source§impl From<f32> for MapGenSize
impl From<f32> for MapGenSize
Source§impl PartialEq for MapGenSize
impl PartialEq for MapGenSize
impl StructuralPartialEq for MapGenSize
Auto Trait Implementations§
impl Freeze for MapGenSize
impl RefUnwindSafe for MapGenSize
impl Send for MapGenSize
impl Sync for MapGenSize
impl Unpin for MapGenSize
impl UnsafeUnpin for MapGenSize
impl UnwindSafe for MapGenSize
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