pub struct Placement {
pub x: f32,
pub y: f32,
pub z: f32,
pub bearing: f32,
}Expand description
Where a door or placeable sits in the area and which way it faces.
The consumer set is the four door and placeable types, blueprint-side placements and saved forms alike. Every one of them reads all four labels with the same zero fallback and writes all four unconditionally, so the block takes no per-consumer parameter.
Encounter and geometry points carry X, Y and Z identically and are
still not consumers. A spawn point faces through Orientation rather than
Bearing, so what counts as three of four shared labels is a position
triple beside a differently-named field. Same shape that keeps a saved
trigger’s trap fields off a saved door’s: shared concept, different label
set. Sharing the triple alone across all eight is a real extraction and a
wider one than this block.
What blocks it is that none of those paths has an audited absent value.
All twenty declarations across the six schema tables are Unexamined, so
merging would assert a sameness nobody has measured. Six of them, the
coordinates under Ute.Geometry and Ute.SpawnPointList, are populated
by no file in either corpus, which is why no further sweep can settle
them and reading the pages is the only thing that can.
That condition covers the four labels this block already shares. Nothing moved when it was introduced, since all four consumers were already reading identical zeros, but an audit giving one path a different absent value now lands here rather than at four separate sites.
Fields§
§x: f32X position (X).
y: f32Y position (Y).
z: f32Z position (Z).
bearing: f32Facing angle in radians (Bearing).
Implementations§
Source§impl Placement
impl Placement
Sourcepub const PARTS: &'static [&'static [Field]]
pub const PARTS: &'static [&'static [Field]]
This type’s schema in parts, which is what a container holding it references.
Own fields first, then one part per flattened child in the order they are declared.
Sourcepub fn read_declared(root: &GffStruct) -> Self
pub fn read_declared(root: &GffStruct) -> Self
Reads every declared field off root.
Absent fields take the entry’s own answer, so a fallback is derived from the declaration rather than restated beside it.
A field declaring a hand-written read is left at that answer for the view to overwrite.
Sourcepub fn write_declared(&self, root: &mut GffStruct)
pub fn write_declared(&self, root: &mut GffStruct)
Writes every declared field onto root, leaving out the ones
their entry says the engine’s own writer leaves out.
A field declaring a hand-written write is not touched here.
Sourcepub fn read_element(structure: &GffStruct) -> Self
pub fn read_element(structure: &GffStruct) -> Self
Reads one element of a list of this type.
Sourcepub fn write_element(&self, structure: &mut GffStruct)
pub fn write_element(&self, structure: &mut GffStruct)
Writes one element of a list of this type.