C# Class kOS.Suffixed.GeoCoordinates

Inheritance: kOS.Suffixed.SpecialValue
Mostra file Open project: KSP-KOS/KOS Class Usage Examples

Public Methods

Method Description
Dump ( ) : Dump
GeoCoordinates ( ) : System
GeoCoordinates ( CelestialBody body, SharedObjects sharedObj, double latitude, double longitude ) : System

Build a GeoCoordinates from any arbitrary lat/long pair of floats.

GeoCoordinates ( Orbitable orb, SharedObjects sharedObj ) : System

Build a GeoCoordinates from the current lat/long of the orbitable object passed in. The object being checked for should be in the same SOI as the vessel running the CPU or the results are meaningless.

GeoCoordinates ( SharedObjects sharedObj, double latitude, double longitude ) : System

Build a GeoCoordinates from any arbitrary lat/long pair of doubles.

GeoCoordinates ( SharedObjects sharedObj, float latitude, float longitude ) : System

Build a GeoCoordinates from any arbitrary lat/long pair of floats.

GetAltitudePosition ( ScalarValue altitude ) : Vector

The point above or below the surface of this LAT/LONG from where the current CPU vessel is now.

GetAltitudeVelocities ( ScalarValue altitude ) : OrbitableVelocity

The pair of velocities representing this spot's velocity due to planetary rotation, at this (sea level) altitude:

GetBearing ( ) : ScalarValue

The bearing from the current CPU vessel to the surface spot with the given lat/long coords, relative to the current CPU vessel's heading.

GetPosition ( ) : Vector

The surface point of this LAT/LONG from where the current CPU vessel is now.

GetTerrainAltitude ( ) : ScalarValue

Returns the ground's altitude above sea level at this geo position.

GetVelocities ( ) : OrbitableVelocity

The pair of velocities representing this spot's velocity due to planetary rotation.

LoadDump ( Dump dump ) : void
SetSharedObjects ( SharedObjects sharedObjects ) : void
ToString ( ) : string

Private Methods

Method Description
GeoCoordsInitializeSuffixes ( ) : void
GetDistanceFrom ( ) : ScalarValue

The distance of the surface point of this LAT/LONG from where the current CPU vessel is now.

GetHeadingFrom ( ) : ScalarValue

The compass heading from the current position of the CPU vessel to the LAT/LANG position on the SOI body's surface.

Method Details

Dump() public method

public Dump ( ) : Dump
return Dump

GeoCoordinates() public method

public GeoCoordinates ( ) : System
return System

GeoCoordinates() public method

Build a GeoCoordinates from any arbitrary lat/long pair of floats.
public GeoCoordinates ( CelestialBody body, SharedObjects sharedObj, double latitude, double longitude ) : System
body CelestialBody A different celestial body to select a lat/long for that might not be the current one
sharedObj SharedObjects to know the current CPU's running vessel
latitude double latitude
longitude double longitude
return System

GeoCoordinates() public method

Build a GeoCoordinates from the current lat/long of the orbitable object passed in. The object being checked for should be in the same SOI as the vessel running the CPU or the results are meaningless.
public GeoCoordinates ( Orbitable orb, SharedObjects sharedObj ) : System
orb Orbitable object to take current coords of
sharedObj SharedObjects to know the current CPU's running vessel
return System

GeoCoordinates() public method

Build a GeoCoordinates from any arbitrary lat/long pair of doubles.
public GeoCoordinates ( SharedObjects sharedObj, double latitude, double longitude ) : System
sharedObj SharedObjects to know the current CPU's running vessel
latitude double latitude
longitude double longitude
return System

GeoCoordinates() public method

Build a GeoCoordinates from any arbitrary lat/long pair of floats.
public GeoCoordinates ( SharedObjects sharedObj, float latitude, float longitude ) : System
sharedObj SharedObjects to know the current CPU's running vessel
latitude float latitude
longitude float longitude
return System

GetAltitudePosition() public method

The point above or below the surface of this LAT/LONG from where the current CPU vessel is now.
public GetAltitudePosition ( ScalarValue altitude ) : Vector
altitude ScalarValue The (sea level) altitude to get a position for
return Vector

GetAltitudeVelocities() public method

The pair of velocities representing this spot's velocity due to planetary rotation, at this (sea level) altitude:
public GetAltitudeVelocities ( ScalarValue altitude ) : OrbitableVelocity
altitude ScalarValue
return OrbitableVelocity

GetBearing() public method

The bearing from the current CPU vessel to the surface spot with the given lat/long coords, relative to the current CPU vessel's heading.
public GetBearing ( ) : ScalarValue
return ScalarValue

GetPosition() public method

The surface point of this LAT/LONG from where the current CPU vessel is now.
public GetPosition ( ) : Vector
return Vector

GetTerrainAltitude() public method

Returns the ground's altitude above sea level at this geo position.
public GetTerrainAltitude ( ) : ScalarValue
return ScalarValue

GetVelocities() public method

The pair of velocities representing this spot's velocity due to planetary rotation.
public GetVelocities ( ) : OrbitableVelocity
return OrbitableVelocity

LoadDump() public method

public LoadDump ( Dump dump ) : void
dump Dump
return void

SetSharedObjects() public method

public SetSharedObjects ( SharedObjects sharedObjects ) : void
sharedObjects SharedObjects
return void

ToString() public method

public ToString ( ) : string
return string