Difference between revisions of "Template:Body data"
From Kerbal Space Program Wiki
(+soi redirect;) |
(+cat pages that use soi; +warning about this parameter;) |
||
Line 7: | Line 7: | ||
|pressure={{BodyData/Pressure|{{{1}}}}} | |pressure={{BodyData/Pressure|{{{1}}}}} | ||
|scale height={{BodyData/ScaleHeight|{{{1}}}}} | |scale height={{BodyData/ScaleHeight|{{{1}}}}} | ||
− | |soi={{BodyData/SOI|{{{1}}}|∞}} | + | |soi={{BodyData/SOI|{{{1}}}|∞}}[[Category:BodyData/SOI]] |
− | |#default={{#explode:{{#explode:{{#explode:{{msgnw::{{{1|}}}/Data}}|{{{2|}}}=|1}}|||0}}|}}|0 | + | |#default={{#explode:{{#explode:{{#explode:{{msgnw::{{{1|}}}/Data}}|{{{2|}}}=|1}}|||0}}|}}|0}}}</includeonly><noinclude> |
Returns for each [[celestial body]] various data about it. | Returns for each [[celestial body]] various data about it. | ||
Line 24: | Line 24: | ||
* <tt>pressure</tt>: {{Tl|BodyData/Pressure}} (returns the pressure at 0 m altitude (“sea level”)) | * <tt>pressure</tt>: {{Tl|BodyData/Pressure}} (returns the pressure at 0 m altitude (“sea level”)) | ||
* <tt>scale height</tt>: {{Tl|BodyData/ScaleHeight}} | * <tt>scale height</tt>: {{Tl|BodyData/ScaleHeight}} | ||
− | * <tt>soi</tt>: {{Tl|BodyData/SOI}} (returns ∞, when the template returns an empty string) | + | * <tt>soi</tt>: {{Tl|BodyData/SOI}} (returns ∞, when the template returns an empty string; There is currently a bug, that this command isn't working correctly: <tt><nowiki>{{BodyData|Kerbin|soi}}</nowiki></tt> doesn't work but <tt><nowiki>{{subst:BodyData|Kerbin|soi}}</nowiki></tt> does; [[:Category:BodyData/SOI|Pages using this parameter]]) |
'''The direct usage of those subtemplates is not recommended anymore!''' | '''The direct usage of those subtemplates is not recommended anymore!''' | ||
Revision as of 10:59, 11 September 2013
Returns for each celestial body various data about it.
For backwards compatibility this template also supports the following properties. It simply calls the apropiate subtemplate.
- apoapsis: {{BodyData/Apoapsis}}
- periapsis: {{BodyData/Periapsis}}
- parent: {{BodyData/Parent}}
- radius: {{BodyData/Radius}}
- mass: {{BodyData/Mass}}
- pressure: {{BodyData/Pressure}} (returns the pressure at 0 m altitude (“sea level”))
- scale height: {{BodyData/ScaleHeight}}
- soi: {{BodyData/SOI}} (returns ∞, when the template returns an empty string; There is currently a bug, that this command isn't working correctly: {{BodyData|Kerbin|soi}} doesn't work but {{subst:BodyData|Kerbin|soi}} does; Pages using this parameter)
The direct usage of those subtemplates is not recommended anymore!
Separate subtemplates
Some special properties can be accessed via a separate sub template
- Name: {{BodyData/Name}}
- Surface gravity: {{BodyData/Gravity}}
- Siderial orbit period: {{BodyData/Sidereal orbit}}
- Sphere of influence: {{BodyData/SOI}}