Struct de_pathing::PathQueryProps 
source · pub struct PathQueryProps {
    distance: f32,
    max_distance: f32,
}Fields§
§distance: f32§max_distance: f32Implementations§
source§impl PathQueryProps
 
impl PathQueryProps
sourcepub fn new(distance: f32, max_distance: f32) -> Self
 
pub fn new(distance: f32, max_distance: f32) -> Self
Create new query properties. When possible, a path whose end is between
distance and max_distance from the target will be searched for.
Paths whose end is closer to the target are preferred.
§Arguments
- 
distance- desired path finishes this distance from the target. If the target is already closer thandistancean empty path is desired (rather than a path going away from the target). - 
max_distance- when all points up tomax_distancefrom the target are unreachable, it is desired that no path is found. This value must be equal or greater thandistance. 
§Panics
- 
May panic if
distanceis not a finite non-negative number. - 
May panic if
max_distanceis not a positive infinity or a finite non-negative number. - 
May panic if
distanceis greater thanmax_distance. 
sourcepub fn exact() -> Self
 
pub fn exact() -> Self
Crate new query properties with both distance and max distance equal to
0. See Self::new.
pub fn distance(&self) -> f32
pub fn max_distance(&self) -> f32
Trait Implementations§
source§impl Clone for PathQueryProps
 
impl Clone for PathQueryProps
source§fn clone(&self) -> PathQueryProps
 
fn clone(&self) -> PathQueryProps
1.0.0 · source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for PathQueryProps
Auto Trait Implementations§
impl Freeze for PathQueryProps
impl RefUnwindSafe for PathQueryProps
impl Send for PathQueryProps
impl Sync for PathQueryProps
impl Unpin for PathQueryProps
impl UnwindSafe for PathQueryProps
Blanket Implementations§
§impl<T, U> AsBindGroupShaderType<U> for T
 
impl<T, U> AsBindGroupShaderType<U> for T
§fn as_bind_group_shader_type(&self, _images: &RenderAssets<Image>) -> U
 
fn as_bind_group_shader_type(&self, _images: &RenderAssets<Image>) -> U
T [ShaderType] for self. When used in [AsBindGroup]
derives, it is safe to assume that all images in self exist.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
§impl<T> Downcast for Twhere
    T: Any,
 
impl<T> Downcast for Twhere
    T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
 
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
 
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
 
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
 
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
 
impl<T> DowncastSync for T
§impl<S> FromSample<S> for S
 
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
§impl<T> Instrument for T
 
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
 
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
 
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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§impl<SS, SP> SupersetOf<SS> for SPwhere
    SS: SubsetOf<SP>,
 
impl<SS, SP> SupersetOf<SS> for SPwhere
    SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
 
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
 
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
 
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
 
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.