Gravity Engine  1.5
Unity Asset for Gravity
SolarBody Class Reference

Solar body. A "data container" delegate used to hold information about a Solar System body. This is a collection of orbital parameters and some additional facts (mass, radius) that is useful for scaling and configuring the solar system. More...

Inheritance diagram for SolarBody:

Public Member Functions

void UpdateOrbit ()
 
void CopyFrom (SolarBody sb)
 
void SetEllipseForEpoch (float epoch, EllipseBase ellipseBase)
 Sets the ellipse parameters for epoch provided. More...
 

Public Attributes

float ecc
 eccentricity (0..1, 0=circle, 1=linear)
 
float a = 10f
 semi-major axis - based on paramBy user can specify a OR p. a = p/(1-ecc)
 
float p = 10f
 
float omega_uc
 "longitude of ascending node" - angle from x-axis to line from focus to pericenter
 
float omega_lc
 "argument of perienter" - angle from ascending node to pericenter
 
float omega_lc_bar
 
float inclination
 inclination (degrees!)
 
float longitude
 longitude
 
float a_dot
 Orbit element variations.
 
float ecc_dot
 
float inclination_dot
 
float omega_lc_bar_dot
 
float omega_uc_dot
 
float longitudeDot
 
float mass_1E24
 Mass/name/size are filled in when created via SolarSystemData. These hold the original values to allow the values to be restored after "what-if" experiments tweaking with values in the NBody. More...
 
float radiusKm
 Scale size of the object.
 
SolarSystem.Type bodyType
 
float epoch
 
SolarSystem solarSystem
 Solar System this object belongs to.
 

Detailed Description

Solar body. A "data container" delegate used to hold information about a Solar System body. This is a collection of orbital parameters and some additional facts (mass, radius) that is useful for scaling and configuring the solar system.

This object acts as the keeper of the "real data" and it's values are used when the "Restore Defaults" is triggered in the SolarSystem inspector or the scale is changed.

Typically only referenced in SolarSystem and filled in from one of the creation classes: PlanetData, AsteroidData or CometData.

Member Function Documentation

void SolarBody.SetEllipseForEpoch ( float  epoch,
EllipseBase  ellipseBase 
)

Sets the ellipse parameters for epoch provided.

Parameters
epochEpoch.
ellipseBaseEllipse base.

Member Data Documentation

float SolarBody.mass_1E24

Mass/name/size are filled in when created via SolarSystemData. These hold the original values to allow the values to be restored after "what-if" experiments tweaking with values in the NBody.

absolute mass in 10^24 kg (when created via SolarSystemData)


The documentation for this class was generated from the following file: