[][src]Struct oxygengine_navigation::resource::NavArea

#[repr(C)]pub struct NavArea {
    pub triangle: u32,
    pub size: f32,
    pub cost: f32,
    pub center: NavVec3,
    pub radius: f32,
    pub radius_sqr: f32,
}

Nav mesh area descriptor. Nav mesh area holds information about specific nav mesh triangle.

Fields

triangle: u32

Triangle index.

size: f32

Area size (triangle area value).

cost: f32

Traverse cost factor. Big values tells that this area is hard to traverse, smaller tells the opposite.

center: NavVec3

Triangle center point.

radius: f32

Radius of sphere that contains this triangle.

radius_sqr: f32

Squared version of radius.

Implementations

impl NavArea[src]

pub fn calculate_area(a: NavVec3, b: NavVec3, c: NavVec3) -> f32[src]

Calculate triangle area value.

Arguments

  • a - first vertice point.
  • b - second vertice point.
  • c - thirs vertice point.

pub fn calculate_center(a: NavVec3, b: NavVec3, c: NavVec3) -> NavVec3[src]

Calculate triangle center point.

Arguments

  • a - first vertice point.
  • b - second vertice point.
  • c - thirs vertice point.

Trait Implementations

impl Clone for NavArea[src]

impl Debug for NavArea[src]

impl Default for NavArea[src]

impl<'de> Deserialize<'de> for NavArea[src]

impl Serialize for NavArea[src]

Auto Trait Implementations

impl RefUnwindSafe for NavArea

impl Send for NavArea

impl Sync for NavArea

impl Unpin for NavArea

impl UnwindSafe for NavArea

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Any for T where
    T: Any

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> Event for T where
    T: Send + Sync + 'static, 

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Resource for T where
    T: Any, 

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> TryDefault for T where
    T: Default

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,