Conquer Space 0.0.0
A space themed grand strategy game set in the near future, with realistic orbital mechanics, and an emphasis on economics and politics.
Classes | Typedefs | Functions | Variables
cqsp::core::components::bodies Namespace Reference

Classes

struct  Atmosphere
 
struct  Body
 
class  ConcatIter
 
class  ConcatView
 
struct  DirtyOrbit
 
struct  EndIter
 
struct  ExpandedIter
 
struct  ExpandedIter< R, Ranges... >
 
struct  ExpandedIter<>
 
struct  GetFirstTypeT
 
struct  LightEmitter
 
struct  NautralObject
 
struct  OrbitalSystem
 An object for the children of an orbital object. More...
 
struct  Planet
 
struct  Star
 
struct  TexturedTerrain
 

Typedefs

template<typename... Pack>
using GetFirstType = GetFirstTypeT< Pack... >::Type
 

Functions

double CalculateSOI (const double &mass, const double &reference_mass, const double &sma)
 Calculates SOI More...
 
double CalculateMass (const double &GM)
 Calculates mass from gravitational constant More...
 
double GetPlanetRotationAngle (const double &time, const double &day_length, const double &offset)
 Calculates the current planet rotation angle More...
 
template<typename... Rs>
bool operator== (const ConcatIter< Rs... > &iter, EndIter)
 

Variables

template<typename... Rs>
return v
 

Typedef Documentation

◆ GetFirstType

template<typename... Pack>
using cqsp::core::components::bodies::GetFirstType = typedef GetFirstTypeT<Pack...>::Type

Function Documentation

◆ CalculateMass()

double cqsp::core::components::bodies::CalculateMass ( const double &  GM)
inline

Calculates mass from gravitational constant

Masses of bodies are described in gravitational constant because it's more accurate to describe like that

Parameters
GM
Returns

◆ CalculateSOI()

double cqsp::core::components::bodies::CalculateSOI ( const double &  mass,
const double &  reference_mass,
const double &  sma 
)
inline

Calculates SOI

Make sure the units match up

Parameters
massMass of planet/body to calculate
reference_massMass of sun/reference body
smaSemi major axis of the planet
Returns
SOI of planet

◆ GetPlanetRotationAngle()

double cqsp::core::components::bodies::GetPlanetRotationAngle ( const double &  time,
const double &  day_length,
const double &  offset 
)
inline

Calculates the current planet rotation angle

Parameters
timecurrent time in seconds
day_lengthlength of day in seconds
offsetoffset of day
Returns
Angle the planet should be in radians

◆ operator==()

template<typename... Rs>
bool cqsp::core::components::bodies::operator== ( const ConcatIter< Rs... > &  iter,
EndIter   
)

Variable Documentation

◆ v

template<typename... Rs>
return cqsp::core::components::bodies::v
Initial value:
{
ConcatView<Rs...> v(std::forward<Rs>(rs)...)
return v
Definition: bodies.h:193