Struct VESSELSTATUS

Source
#[repr(C)]
pub struct VESSELSTATUS {
Show 14 fields pub rpos: VECTOR3, pub rvel: VECTOR3, pub vrot: VECTOR3, pub arot: VECTOR3, pub fuel: f64, pub eng_main: f64, pub eng_hovr: f64, pub rbody: OBJHANDLE, pub base: OBJHANDLE, pub port: i32, pub status: i32, pub vdata: [VECTOR3; 10], pub fdata: [f64; 10], pub flag: [DWORD; 10],
}
Expand description

Binding for OrbiterSDK’s VESSELSTATUS struct

Fields§

§rpos: VECTOR3

Position relative to rbody in ecliptic frame [m]

§rvel: VECTOR3

Velocity relative to rbody in ecliptic frame [m/s]

§vrot: VECTOR3

Rotation velocity about principal axes in ecliptic frame [rad/s]

§arot: VECTOR3

Vessel orientation against ecliptic frame

§fuel: f64

Fuel level. Between 0 and 1.

§eng_main: f64

Main/retro engine setting. Between -1 and 1.

§eng_hovr: f64

Hover engine setting. Between 0 and 1.

§rbody: OBJHANDLE

Handle of reference body

§base: OBJHANDLE

Handle of docking or landing target

§port: i32

Index of designated docking or landing port

§status: i32

Flight status indicator

  • 0 = active (freeflight)
  • 1 = inactive (landed)
§vdata: [VECTOR3; 10]

Additional vector parameters

  • vdata[0]: contains landing parameters

    if status is equal to 1, vdata[0] contains the longitude, latitude, and heading of landed vessel

  • vdata[1] - vdata[9]: not used

§fdata: [f64; 10]

additional floating point parameters (not used)

§flag: [DWORD; 10]

Additional integer and bitflag parameters

  • flag[0] & 1:

  • flag[0] & 2:

    • 0: ignore fuel level, do not change fuel levels
    • 1: set fuel level of first propellant resource from fuel
  • flag[1] - flag[9]: not used

Trait Implementations§

Source§

impl Debug for VESSELSTATUS

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for VESSELSTATUS

Source§

fn default() -> VESSELSTATUS

Returns the “default value” for a type. Read more
Source§

impl ExternType for VESSELSTATUS

Source§

type Id = (V, E, S, S, E, L, S, T, A, T, U, S)

A type-level representation of the type’s C++ namespace and type name. Read more
Source§

type Kind = Trivial

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.