pub enum RegionShape {
Box {
frame: EditFrame,
min: [i32; 3],
max: [i32; 3],
},
SurfaceBand {
over: RegionId,
from: i32,
to: i32,
},
PaletteMatch {
within: RegionId,
blocks: Vec<String>,
},
Union {
of: Vec<RegionId>,
},
Intersect {
of: Vec<RegionId>,
},
Subtract {
base: RegionId,
remove: Vec<RegionId>,
},
}Expand description
A select verb’s shape (spec-0017): primitive shapes resolve in a declared
frame; compositions combine earlier regions of the same batch.
Variants§
Box
An inclusive axis-aligned box, min/max in the declared frame.
Fields
SurfaceBand
The band of cells at from..=to blocks relative to each column’s
terrain surface (the highest non-air cell of the column) within an
earlier region. from: 1, to: 3 is the 3 cells of air-space above the
surface; from: 0, to: 0 is the surface cells themselves; negative
offsets reach below the surface.
Fields
PaletteMatch
The cells of an earlier region whose current block matches one of
blocks (base ids; blockstate suffixes ignored when matching).
Fields
Union
The union of earlier regions.
Intersect
The intersection of earlier regions.
Subtract
An earlier region minus other earlier regions.
Trait Implementations§
Source§impl Clone for RegionShape
impl Clone for RegionShape
Source§impl Debug for RegionShape
impl Debug for RegionShape
Source§impl<'de> Deserialize<'de> for RegionShape
impl<'de> Deserialize<'de> for RegionShape
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for RegionShape
impl JsonSchema for RegionShape
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for RegionShape
impl PartialEq for RegionShape
Source§impl Serialize for RegionShape
impl Serialize for RegionShape
impl StructuralPartialEq for RegionShape
Auto Trait Implementations§
impl Freeze for RegionShape
impl RefUnwindSafe for RegionShape
impl Send for RegionShape
impl Sync for RegionShape
impl Unpin for RegionShape
impl UnsafeUnpin for RegionShape
impl UnwindSafe for RegionShape
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