Difference between revisions of "Template:Infobox/Body"

From Kerbal Space Program Wiki
Jump to: navigation, search
m (+show velocity at SoI;)
m (!oops doesn't depend on pressure;)
Line 71: Line 71:
 
| style="font-size:smaller;" | {{ExpandTime|{{{sidrot}}}}}
 
| style="font-size:smaller;" | {{ExpandTime|{{{sidrot}}}}}
 
|-
 
|-
| {{lang|en=[[w:Sidereal_time|Sidereal Rotational Velocity]]|nl=[[w:Sidereal_time|Sterrenomloop snelheid]]|fr=[[w:fr:Temps Sidéral|Temps Sidéral]]|pl=[[w:pl:Czas_gwiazdowy|Gwiazdowa prędkość obrotowa]]|ru=[[w:ru:Звёздное_время|Экваториальная скорость вращения]]|de=[[w:Sidereal time|Rotations­geschwindig­keit]]}}
+
| valign="top" | {{lang|en=[[w:Sidereal_time|Sidereal Rotational Velocity]]|nl=[[w:Sidereal_time|Sterrenomloop snelheid]]|fr=[[w:fr:Temps Sidéral|Temps Sidéral]]|pl=[[w:pl:Czas_gwiazdowy|Gwiazdowa prędkość obrotowa]]|ru=[[w:ru:Звёздное_время|Экваториальная скорость вращения]]|de=[[w:Sidereal time|Rotations­geschwindig­keit]]}}
| {{sigfigs|{{#expr: {{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}} * 2 * pi / {{{sidrot}}}}}|5}} m/s
+
| valign="top" | {{sigfigs|{{#expr: {{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}} * 2 * pi / {{{sidrot}}}}}|5}} m/s
 
|-
 
|-
| {{lang|en=[[w:Synchronous_orbit|Synchronous Orbit]]|nl=[[w:Synchronous_orbit|Synchrone omloop]]|fr=[[w:fr:Orbite Synchrone|Orbite Synchrone]]|pl=[[w:Synchronous_orbit|Orbita synchroniczna]]|ru=[[w:ru:Синхронная_орбита|Синхронная орбита]]|de=[[w:de:Geosynchrone Umlaufbahn|Synchrone Umlaufbahn]]}}
+
| valign="top" | {{lang|en=[[w:Synchronous_orbit|Synchronous Orbit]]|nl=[[w:Synchronous_orbit|Synchrone omloop]]|fr=[[w:fr:Orbite Synchrone|Orbite Synchrone]]|pl=[[w:Synchronous_orbit|Orbita synchroniczna]]|ru=[[w:ru:Синхронная_орбита|Синхронная орбита]]|de=[[w:de:Geosynchrone Umlaufbahn|Synchrone Umlaufbahn]]}}
 
| {{#if: {{#ifeq: {{{SoI}}}|∞|1}}{{#ifexpr: {{OrbitAltitude | radius_m={{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}} | mass_kg={{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} | period_s={{{sidrot}}} | suffix= }} < {{{SoI}}}|1}}|{{sigfigs|{{OrbitAltitude | radius_m={{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}} | mass_kg={{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} | period_s={{{sidrot}}} | suffix=  }}|8}}&nbsp;m|{{lang|en=Outside sphere of influence|pl=Poza sferą wpływów|ru=За пределами сферы влияния|de=Außerhalb der Sphere of Influence}}}}
 
| {{#if: {{#ifeq: {{{SoI}}}|∞|1}}{{#ifexpr: {{OrbitAltitude | radius_m={{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}} | mass_kg={{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} | period_s={{{sidrot}}} | suffix= }} < {{{SoI}}}|1}}|{{sigfigs|{{OrbitAltitude | radius_m={{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}} | mass_kg={{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} | period_s={{{sidrot}}} | suffix=  }}|8}}&nbsp;m|{{lang|en=Outside sphere of influence|pl=Poza sferą wpływów|ru=За пределами сферы влияния|de=Außerhalb der Sphere of Influence}}}}
 
|-
 
|-
| {{#if: {{#ifeq: {{{SoI|}}}|∞|1}}{{#ifexpr: {{BodyData/Pressure|{{{Name|{{BASEPAGENAME}}}}}}}>0|1}}| rowspan="2" {{!}}}} {{lang|en=[[w:Sphere_of_influence_(astrodynamics)|Sphere of Influence]]|nl=[[w:nl:Invloedssfeer van een hemellichaam|Invloedssfeer]]|fr=[[w:Sphere_of_Influence_(astrodynamics)|Sphère d'Influence]]|pl=[[w:Sphere_of_influence_(astrodynamics)|Sfera wpływów]]|ru=[[w:Sphere_of_influence_(astrodynamics)|Сфера влияния]]|de=[[w:de:Sphere of Influence|Sphere of Influence]]}}
+
| {{#if: {{#ifeq: {{{SoI|}}}|∞|1}}| rowspan="2" }} valign="top" | {{lang|en=[[w:Sphere_of_influence_(astrodynamics)|Sphere of Influence]]|nl=[[w:nl:Invloedssfeer van een hemellichaam|Invloedssfeer]]|fr=[[w:Sphere_of_Influence_(astrodynamics)|Sphère d'Influence]]|pl=[[w:Sphere_of_influence_(astrodynamics)|Sfera wpływów]]|ru=[[w:Sphere_of_influence_(astrodynamics)|Сфера влияния]]|de=[[w:de:Sphere of Influence|Sphere of Influence]]}}
 
| {{#ifeq: {{{SoI|}}}|∞|∞|{{sigfigs|{{{SoI}}}|8}}&nbsp;m}}
 
| {{#ifeq: {{{SoI|}}}|∞|∞|{{sigfigs|{{{SoI}}}|8}}&nbsp;m}}
{{#if: {{#ifeq: {{{SoI|}}}|∞|1}}{{#ifexpr: {{BodyData/Pressure|{{{Name|{{BASEPAGENAME}}}}}}}>0|1}}|
+
{{#if: {{#ifeq: {{{SoI|}}}|∞|1}}|
 
{{!}}-
 
{{!}}-
 
{{!}} style="font-size:smaller;" {{!}} {{sigfigs|{{#expr: {{G}}*{{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}}/{{{SoI}}}^2 * 1000}}|3}} mm/s²
 
{{!}} style="font-size:smaller;" {{!}} {{sigfigs|{{#expr: {{G}}*{{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}}/{{{SoI}}}^2 * 1000}}|3}} mm/s²

Revision as of 10:46, 25 March 2013

Template:Planetbox

Usage

To avoid adding the information for each language this template should be used for each celestial body once (e.g. Duna/Data) and each page using that Planetbox (e.g. Duna itself) could use it with {{:Duna/Data}}.

Parameters

Name Optional Description
Name Yes Name of celestial body. Used to determine mass. Default: {{BASEPAGENAME}}
Class No Class of celestial body. This will be translated!
File No Filename to image of the celestial object
Parent Yes Object which this object does orbit. If net set it hides the orbital information. Default: Not set
apoap No Apoapsis in meters from parents center
periap Yes Periapsis in meters from parents center. Default: Apoapsis
orbinc No Orbital inclination in degrees.
anomaly No Mean anomaly in degrees
sidrot No Siderial period in seconds
SoI No Sphere of influence in meters. Special value: ∞
highest Yes Highest elevation in meters. Default: Not set
Atmospheric data are only needed if it has an atmosphere
atmossh No Atmospheric scale height in meters
T-minC No Lowest temperature in degrees celsius
T-maxC No Highest temperature in degrees celsius
O2yorn No Is oxygen present? (Yes/No)

To deactivate orbital information (for example Kerbol) don't set {{{Parent}}}. The atmospheric information is hidden when {{BodyData/Pressure}} returns a value higher than 0.

If the periapsis isn't defined it will assume a circular orbit where the apoapsis is identical to the periapsis. For the mass, radius and pressure at sealevel it uses the {{BodyData}} templates.

Ingame the apsis is calculated from the body surface. But because all values which depend on them needs to be from the center the values must be from the parent center.

Dependencies

Some values are calculated automatically:

  • Periapsis: Semi-major axis, Orbital eccentricity, Orbital velocity
  • Apoapsis: Semi-major axis, Orbital eccentricity, Orbital velocity
  • Orbital period: Orbital velocity
  • Radius: Surface Area, Density, Surface Gravity, Synchronous Orbit
  • Mass: Gravitational Parameter, Density, Surface Gravity, Synchronous Orbit
  • Sidereal Rotation Period: Sidereal Rotational Velocity, Synchronous Orbit
  • Scale Height: Atmospheric Height
  • Atmospheric pressure (in atm): Atmospheric pressure (in kPa)

Template

{{Planetbox
|Name=
|Class=
|File=
|Parent= 
|apoap=
|periap=
|orbinc=
|anomaly=
|sidrot=
|SoI=
|highest=
|atmossh=
|T-minC=
|T-maxC=
|O2yorn=
}}

Example

Example used on this page:

{{Planetbox
|Class=Planet
|File=Image-needed.png
|Parent=Gilly
|apoap=1337000
|periap=470000
|orbinc=7.4
|anomaly=4.2
|orbps=36000
|sidrot=3600
|SoI=200000
|highest=2357
|atmossh=3000
|T-minC=-42
|T-maxC=47
|O2yorn=no
}}

Translating

This template support following languages:

  • English: Everything supported
  • Nederlands (Dutch): Subsections (like “Orbital Characteristics”) and most of the columns are supported
  • Français (French): Subsections (like “Orbital Characteristics”) and most of the columns are supported
  • Русский (Russian): Everything supported
  • Polski (Polish): Everything supported
  • German (Deutsch): Everything supported