pub struct StateAssignment(pub BTreeMap<String, u32>);Expand description
Values for axes by key (a save snapshot): above each axis’s default, below resolve-state’s assign option.
Tuple Fields§
§0: BTreeMap<String, u32>Trait Implementations§
Source§impl Clone for StateAssignment
impl Clone for StateAssignment
Source§impl Debug for StateAssignment
impl Debug for StateAssignment
Source§impl Default for StateAssignment
impl Default for StateAssignment
impl Eq for StateAssignment
Source§impl PartialEq for StateAssignment
impl PartialEq for StateAssignment
Source§impl Resource for StateAssignment
impl Resource for StateAssignment
const NAME: &'static str = "core.state_assignment"
const VERSION: u32 = 1
Source§fn verify(&self, _w: &World) -> Result<(), String>
fn verify(&self, _w: &World) -> Result<(), String>
The resource’s own invariants in
w; as Component::verify, run by the pass manager’s verifier.Source§fn references(&self, _out: &mut Vec<Entity>)
fn references(&self, _out: &mut Vec<Entity>)
The entities this resource refers to, appended to
out. A resource holding entity references must declare
every one of them and implement Resource::retain_references.Source§fn retain_references(&mut self, _keep: &dyn Fn(Entity) -> bool)
fn retain_references(&mut self, _keep: &dyn Fn(Entity) -> bool)
Forget every reference to an entity
keep refuses (set it to “none”). The world calls it whenever entities
leave it (World::despawn, World::retain, World::move_components) and on the copy a
World::subset or World::split_off part gets, so a resource never refers to an entity its world lacks.Source§impl Serialize for StateAssignment
impl Serialize for StateAssignment
impl StructuralPartialEq for StateAssignment
Auto Trait Implementations§
impl Forget for StateAssignment
impl Freeze for StateAssignment
impl RefUnwindSafe for StateAssignment
impl Send for StateAssignment
impl Sync for StateAssignment
impl Unpin for StateAssignment
impl UnsafeUnpin for StateAssignment
impl UnwindSafe for StateAssignment
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.