Difference between revisions of "Template:Infobox/Body"

From Kerbal Space Program Wiki
Jump to: navigation, search
(*using Template:BodyData subtemplates;)
Line 46: Line 46:
 
|-
 
|-
 
| {{lang|en=[[w:Radius|Equatorial Radius]]|nl=[[w:nl:Radius|Equatoriale radius]]|fr=[[w:Radius|Rayon à l'Equateur]]|pl=[[w:pl:Promień_(geometria)|Promień równika]]|ru=[[w:ru:Радиус|Экваториальный радиус]]}}
 
| {{lang|en=[[w:Radius|Equatorial Radius]]|nl=[[w:nl:Radius|Equatoriale radius]]|fr=[[w:Radius|Rayon à l'Equateur]]|pl=[[w:pl:Promień_(geometria)|Promień równika]]|ru=[[w:ru:Радиус|Экваториальный радиус]]}}
| {{formatnum: {{{radius}}}}} m
+
| {{formatnum: {{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}}}} m
 
|-
 
|-
 
| {{lang|en=[[w:Surface Area|Surface Area]]|nl=[[w:nl:Oppervlakte|Oppervlakte]]|fr=[[w:fr:Surface Area|Surface]]|pl=[[w:pl:Pole_powierzchni|Pole powierzchni]]|ru=[[w:ru:Площадь_поверхности|Площадь поверхности]]}}
 
| {{lang|en=[[w:Surface Area|Surface Area]]|nl=[[w:nl:Oppervlakte|Oppervlakte]]|fr=[[w:fr:Surface Area|Surface]]|pl=[[w:pl:Pole_powierzchni|Pole powierzchni]]|ru=[[w:ru:Площадь_поверхности|Площадь поверхности]]}}
| {{sigfigs|{{#expr: 4 * pi * {{{radius}}}^2}}|8}} m<sup>2</sup>
+
| {{sigfigs|{{#expr: 4 * pi * {{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}}^2}}|8}} m<sup>2</sup>
 
|-
 
|-
 
| {{lang|en=[[w:Mass|Mass]]|nl=[[w:nl:Massa|Massa]]|fr=[[w:fr:Masse|Masse]]|pl=[[w:pl:Masa_(fizyka)|Masa]]|ru=[[w:ru:Масса|Масса]]}}
 
| {{lang|en=[[w:Mass|Mass]]|nl=[[w:nl:Massa|Massa]]|fr=[[w:fr:Masse|Masse]]|pl=[[w:pl:Masa_(fizyka)|Masa]]|ru=[[w:ru:Масса|Масса]]}}
| {{sigfigs|{{CelestialBodyMass|{{{Name|{{BASEPAGENAME}}}}}}}|8}} kg
+
| {{sigfigs|{{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}}|8}} kg
 
|-
 
|-
 
| {{lang|en=[[w:Standard gravitational parameter|Gravitational Parameter]]|nl=[[w:nl:Gravitatieconstante|Gravitatieconstante]]|fr=[[w:fr:Paramètre gravitationnel standard|Paramètre gravitationnel standard]]|pl=[[w:Standard_gravitational_parameter|Parametr grawitacyjny]]|ru=[[w:Standard_gravitational_parameter|Гравитационный параметр]]}}
 
| {{lang|en=[[w:Standard gravitational parameter|Gravitational Parameter]]|nl=[[w:nl:Gravitatieconstante|Gravitatieconstante]]|fr=[[w:fr:Paramètre gravitationnel standard|Paramètre gravitationnel standard]]|pl=[[w:Standard_gravitational_parameter|Parametr grawitacyjny]]|ru=[[w:Standard_gravitational_parameter|Гравитационный параметр]]}}
| {{sigfigs|{{#expr: {{CelestialBodyMass|{{{Name|{{BASEPAGENAME}}}}}}} * {{G}}}}|8}} m<sup>3</sup>/s<sup>2</sup>
+
| {{sigfigs|{{#expr: {{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} * {{G}}}}|8}} m<sup>3</sup>/s<sup>2</sup>
 
|-
 
|-
 
| {{lang|en=[[w:Density|Density]]|nl=[[w:nl:Dichtheid (natuurkunde)|Dichtheid]]|fr=[[w:fr:Densité|Densité]]|pl=[[w:pl:Gęstość|Gęstość]]|ru=[[w:ru:Плотность|Плотность]]}}
 
| {{lang|en=[[w:Density|Density]]|nl=[[w:nl:Dichtheid (natuurkunde)|Dichtheid]]|fr=[[w:fr:Densité|Densité]]|pl=[[w:pl:Gęstość|Gęstość]]|ru=[[w:ru:Плотность|Плотность]]}}
| {{sigfigs|{{#expr: {{CelestialBodyMass|{{{Name|{{BASEPAGENAME}}}}}}} / (4 * pi * {{{radius}}}^3 / 3)}}|8}} kg/m<sup>3</sup>
+
| {{sigfigs|{{#expr: {{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} / (4 * pi * {{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}}^3 / 3)}}|8}} kg/m<sup>3</sup>
 
|-
 
|-
 
| {{lang|en=[[w:Surface_gravity|Surface Gravity]]|nl=[[w:Surface_gravity|Oppervlaktezwaartekracht]]|fr=[[w:fr:Gravité de surface|Gravité de surface]]|pl=[[w:Surface_gravity|Grawitacja na powierzchni]]|ru=[[w:Ускорение_свободного_падения|Ускорение свободного падения]]}}
 
| {{lang|en=[[w:Surface_gravity|Surface Gravity]]|nl=[[w:Surface_gravity|Oppervlaktezwaartekracht]]|fr=[[w:fr:Gravité de surface|Gravité de surface]]|pl=[[w:Surface_gravity|Grawitacja na powierzchni]]|ru=[[w:Ускорение_свободного_падения|Ускорение свободного падения]]}}
| {{sigfigs|{{#expr: {{CelestialBodyMass|{{{Name|{{BASEPAGENAME}}}}}}} * {{G}} / ({{{radius}}}^2)}}|3}} m/s<sup>2</sup>
+
| {{sigfigs|{{#expr: {{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} * {{G}} / ({{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}}^2)}}|3}} m/s<sup>2</sup>
 
|-
 
|-
 
| {{lang|en=[[w:Escape_velocity|Escape Velocity]]|nl=[[w:nl:Ontsnappingssnelheid|Ontsnappingssnelheid]]|fr=[[w:fr:Vitesse de Libération|Vitesse de Libération]]|pl=[[w:pl:Prędkość_ucieczki|Prędkość ucieczki]]|ru=[[w:ru:Вторая_космическая_скорость|Вторая космическая скорость]]}}
 
| {{lang|en=[[w:Escape_velocity|Escape Velocity]]|nl=[[w:nl:Ontsnappingssnelheid|Ontsnappingssnelheid]]|fr=[[w:fr:Vitesse de Libération|Vitesse de Libération]]|pl=[[w:pl:Prędkość_ucieczki|Prędkość ucieczki]]|ru=[[w:ru:Вторая_космическая_скорость|Вторая космическая скорость]]}}
| {{#expr: (2 * {{G}} * {{CelestialBodyMass|{{{Name|{{BASEPAGENAME}}}}}}} / {{{radius|1}}})^0.5 round2 }} m/s
+
| {{#expr: (2 * {{G}} * {{BodyData/Mass|{{{Name|{{BASEPAGENAME}}}}}}} / {{BodyData/Radius|{{{Name|{{BASEPAGENAME}}}}}}})^0.5 round2 }} m/s
 
|-
 
|-
 
| valign="top" rowspan="2" | {{lang|en=[[w:Rotation_period|Sidereal Rotation Period]]|nl=[[w:nl:Rotatieperiode|Rotatieperiode]]|fr=[[w:fr:Période de Rotation|Période de Rotation]]|pl=[[w:pl:Okres_obrotu|Okres obrotu]]|ru=[[w:ru:Период_вращения|Период вращения]]}}
 
| valign="top" rowspan="2" | {{lang|en=[[w:Rotation_period|Sidereal Rotation Period]]|nl=[[w:nl:Rotatieperiode|Rotatieperiode]]|fr=[[w:fr:Période de Rotation|Période de Rotation]]|pl=[[w:pl:Okres_obrotu|Okres obrotu]]|ru=[[w:ru:Период_вращения|Период вращения]]}}
Line 72: Line 72:
 
|-
 
|-
 
| {{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:Звёздное_время|Экваториальная скорость вращения]]}}
 
| {{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:Звёздное_время|Экваториальная скорость вращения]]}}
| {{sigfigs|{{#expr: {{{radius}}} * 2 * pi / {{{sidrot}}}}}|5}} m/s
+
| {{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:Синхронная_орбита|Синхронная орбита]]}}
 
| {{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:Синхронная_орбита|Синхронная орбита]]}}
| {{#if: {{#ifeq: {{{SoI}}}|∞|1}}{{#ifexpr: {{OrbitAltitude | radius_m={{{radius}}} | mass_kg={{CelestialBodyMass|{{{Name|{{BASEPAGENAME}}}}}}} | period_s={{{sidrot}}} | suffix= }} < {{{SoI}}}|1}}|{{sigfigs|{{OrbitAltitude | radius_m={{{radius}}} | mass_kg={{CelestialBodyMass|{{{Name|{{BASEPAGENAME}}}}}}} | period_s={{{sidrot}}} | suffix=  }}|8}} m|{{lang|en=Outside sphere of influence|pl=Poza sferą wpływów|ru=За пределами сферы влияния}}}}
+
| {{#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}} m|{{lang|en=Outside sphere of influence|pl=Poza sferą wpływów|ru=За пределами сферы влияния}}}}
 
|-
 
|-
 
| {{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)|Сфера влияния]]}}
 
| {{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)|Сфера влияния]]}}
Line 85: Line 85:
 
|-
 
|-
 
| {{lang|en=[[w:atmosphere|Atmosphere Present]]|nl=[[w:nl:Atmosfeer (astronomie)|Atmosfeer aanwezig]]|fr=[[w:atmosphere|Présence d'Atmosphère]]|pl=[[w:pl:Atmosfera|Atmosfera obecna]]|ru=[[w:ru:Атмосфера|Наличие атмосферы]]}}
 
| {{lang|en=[[w:atmosphere|Atmosphere Present]]|nl=[[w:nl:Atmosfeer (astronomie)|Atmosfeer aanwezig]]|fr=[[w:atmosphere|Présence d'Atmosphère]]|pl=[[w:pl:Atmosfera|Atmosfera obecna]]|ru=[[w:ru:Атмосфера|Наличие атмосферы]]}}
| {{#if: {{{atmosatm|}}}|{{Planetbox/Dict|Yes}}|{{Planetbox/Dict|No}}}}
+
| {{#ifexpr: {{BodyData/Pressure|{{{Name|{{BASEPAGENAME}}}}}}}>0|{{Planetbox/Dict|Yes}}
{{#if: {{{atmosatm|}}}|
 
 
{{!}}-
 
{{!}}-
 
{{!}} valign="top" rowspan="2" {{!}} {{lang|en=[[w:Atmospheric_pressure|Atmospheric Pressure]]|nl=[[w:nl:Luchtdruk|Atmosferische druk]]|fr=[[w:fr:Pression Atmosphérique|Pression Atmosphérique]]|pl=[[w:pl:Ciśnienie atmosferyczne|Ciśnienie atmosferyczne]]|ru=[[w:ru:Атмосферное_давление|Атмосферное давление]]}}
 
{{!}} valign="top" rowspan="2" {{!}} {{lang|en=[[w:Atmospheric_pressure|Atmospheric Pressure]]|nl=[[w:nl:Luchtdruk|Atmosferische druk]]|fr=[[w:fr:Pression Atmosphérique|Pression Atmosphérique]]|pl=[[w:pl:Ciśnienie atmosferyczne|Ciśnienie atmosferyczne]]|ru=[[w:ru:Атмосферное_давление|Атмосферное давление]]}}
{{!}} {{sigfigs|{{#expr: {{{atmosatm}}} * 101.327}}|3}} kPa
+
{{!}} {{sigfigs|{{#expr: {{BodyData/Pressure|{{{Name|{{BASEPAGENAME}}}}}}} * 101.327}}|3}} kPa
 
{{!}}-
 
{{!}}-
{{!}} {{{atmosatm}}} atm
+
{{!}} {{BodyData/Pressure|{{{Name|{{BASEPAGENAME}}}}}}} atm
 
{{!}}-
 
{{!}}-
 
{{!}} {{lang|en=[[w:Scale_height|Scale Height]]|fr=[[w:fr:Hauteur_d'échelle|Hauteur_d'échelle]]|pl=[[w:Scale_height|Wysokość skali]]|ru=[[w:Scale_height|Шкала высоты]]}}
 
{{!}} {{lang|en=[[w:Scale_height|Scale Height]]|fr=[[w:fr:Hauteur_d'échelle|Hauteur_d'échelle]]|pl=[[w:Scale_height|Wysokość skali]]|ru=[[w:Scale_height|Шкала высоты]]}}
Line 107: Line 106:
 
{{!}} {{lang|en=[[w:Oxygen|Oxygen Present]]|nl=[[w:nl:Zuurstof|Zuurstof aanwezig]]|fr=[[w:fr:Oxygène|Présence d'Oxygène]]|pl=[[w:pl:Tlen|Tlen Obecny]]|ru=[[w:ru:Кислород|Наличие кислорода]]}}
 
{{!}} {{lang|en=[[w:Oxygen|Oxygen Present]]|nl=[[w:nl:Zuurstof|Zuurstof aanwezig]]|fr=[[w:fr:Oxygène|Présence d'Oxygène]]|pl=[[w:pl:Tlen|Tlen Obecny]]|ru=[[w:ru:Кислород|Наличие кислорода]]}}
 
{{!}} {{#ifeq: {{{O2yorn}}}|Yes|{{Planetbox/Dict|Yes}}|{{Planetbox/Dict|No}}}}
 
{{!}} {{#ifeq: {{{O2yorn}}}|Yes|{{Planetbox/Dict|Yes}}|{{Planetbox/Dict|No}}}}
}}
+
|{{Planetbox/Dict|No}}}}
 
|}
 
|}
 
</div></includeonly><noinclude>
 
</div></includeonly><noinclude>
Line 118: Line 117:
 
|orbinc=7.4
 
|orbinc=7.4
 
|anomaly=4.2
 
|anomaly=4.2
|radius=10000
 
 
|sidrot=3600
 
|sidrot=3600
 
|SoI=200000
 
|SoI=200000
 
|highest=2357
 
|highest=2357
|atmosatm=1
 
 
|atmossh=3000
 
|atmossh=3000
 
|T-minC=-42
 
|T-minC=-42
Line 169: Line 166:
 
| No
 
| No
 
| Mean anomaly in degrees
 
| Mean anomaly in degrees
|-
 
| <tt>radius</tt>
 
| No
 
| Radius in meters
 
 
|-
 
|-
 
| <tt>sidrot</tt>
 
| <tt>sidrot</tt>
Line 186: Line 179:
 
| Highest elevation in meters. Default: Not set
 
| Highest elevation in meters. Default: Not set
 
|-
 
|-
| <tt>atmosatm</tt>
+
| colspan="3" | ''Atmospheric data are only needed if it has an atmosphere''
| Yes
 
| Atmospheric pressure in atm. If this celestial body doesn't have an atmosphere don't set this value. Default: Not set
 
 
|-
 
|-
 
| style="padding-left:2em" | <tt>atmossh</tt>
 
| style="padding-left:2em" | <tt>atmossh</tt>
Line 207: Line 198:
 
|}
 
|}
  
To deactivate orbital information (for example [[Kerbol]]) don't set <tt><nowiki>{{{Parent}}}</nowiki></tt>. The atmospheric information can be hidden when <tt><nowiki>{{{atmosatm}}}</nowiki></tt> isn't set.
+
To deactivate orbital information (for example [[Kerbol]]) don't set <tt><nowiki>{{{Parent}}}</nowiki></tt>. The atmospheric information is hidden when {{Tl|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 it uses {{Tl|CelestialBodyMass}}.
+
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 {{Tl|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.
 
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.
Line 234: Line 225:
 
|orbinc=
 
|orbinc=
 
|anomaly=
 
|anomaly=
|radius=
 
 
|sidrot=
 
|sidrot=
 
|SoI=
 
|SoI=
 
|highest=
 
|highest=
|atmosatm=
 
 
|atmossh=
 
|atmossh=
 
|T-minC=
 
|T-minC=
Line 256: Line 245:
 
|anomaly=4.2
 
|anomaly=4.2
 
|orbps=36000
 
|orbps=36000
|radius=10000
 
 
|sidrot=3600
 
|sidrot=3600
 
|SoI=200000
 
|SoI=200000
 
|highest=2357
 
|highest=2357
|atmosatm=1
 
 
|atmossh=3000
 
|atmossh=3000
 
|T-minC=-42
 
|T-minC=-42

Revision as of 12:57, 13 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