Struct EntityCapabilityKey
pub struct EntityCapabilityKey<T, C = ()>where
T: 'static + ?Sized,
C: 'static,{
pub name: &'static str,
/* private fields */
}Expand description
An entity capability: its name, the handler trait T it answers with, the context C a
lookup passes its providers (NeoForge’s EntityCapability<T, C>: () where NeoForge’s is
Void, the side asked about where it is @Nullable Direction), and the game’s own provider,
if the game has one.
Fields§
§name: &'static strThe name.
Implementations§
§impl<T, C> EntityCapabilityKey<T, C>where
T: 'static + ?Sized,
C: 'static,
impl<T, C> EntityCapabilityKey<T, C>where
T: 'static + ?Sized,
C: 'static,
pub const fn new(name: &'static str) -> EntityCapabilityKey<T, C>
pub const fn new(name: &'static str) -> EntityCapabilityKey<T, C>
A mod’s own entity capability, answered only by the providers registered for it.
Auto Trait Implementations§
impl<T, C> Freeze for EntityCapabilityKey<T, C>where
T: ?Sized,
impl<T, C> RefUnwindSafe for EntityCapabilityKey<T, C>where
T: ?Sized,
impl<T, C> Send for EntityCapabilityKey<T, C>where
T: ?Sized,
impl<T, C> Sync for EntityCapabilityKey<T, C>where
T: ?Sized,
impl<T, C> Unpin for EntityCapabilityKey<T, C>where
T: ?Sized,
impl<T, C> UnsafeUnpin for EntityCapabilityKey<T, C>where
T: ?Sized,
impl<T, C> UnwindSafe for EntityCapabilityKey<T, C>where
T: ?Sized,
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