pub struct FowObserver {
pub cell: IVec2,
pub facing: Vec2,
pub deck: usize,
pub eye_z: i32,
}Expand description
Who is looking: grid-local cell, facing, and active deck index.
The caller converts from world space (crate::world_to_grid_local)
— keeping the mask grid-local makes ship rotation/movement free.
Fields§
§cell: IVec2Observer cell (grid-local mip-0 XY column).
facing: Vec2Facing direction, grid-local XY. Zero disables the cone (peripheral-only vision).
deck: usizeActive deck index into VisionConfig::decks.
eye_z: i32The character’s eye z, grid-local (z-down). LOS is blocked by any
solid voxel within ±EYE_HALF of it, so vision tracks the real
eye over stairs / ramps / boulders — not the deck floor.
Trait Implementations§
Source§impl Clone for FowObserver
impl Clone for FowObserver
Source§fn clone(&self) -> FowObserver
fn clone(&self) -> FowObserver
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 FowObserver
Auto Trait Implementations§
impl Freeze for FowObserver
impl RefUnwindSafe for FowObserver
impl Send for FowObserver
impl Sync for FowObserver
impl Unpin for FowObserver
impl UnsafeUnpin for FowObserver
impl UnwindSafe for FowObserver
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more