Template:PlanetInfoBox: Difference between revisions

From Space Pioneers Community Wiki
mNo edit summary
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
<noinclude>
== Example ==
{{PlanetInfoBox
| planetId = 2128-3
| image = 2128-3_example.png
| date = 06/20/25
| atmosphere = Martian
| tectonics = Continental
| oceans = Water
| radius = 1
| gravity = 1
| moons = 0
| hasLife = false
| description = Small planet, has some interesing buildings near the north pole. Numerous important events in Space Pioneers happened there.
}}
<templatedata>
{
  "description": "Shows information about a planet",
  "params": {
    "planetId": {
      "label": "Planet ID",
      "required": true,
      "description": "The id of the planet (ssss-i)",
      "type": "string"
    },
  "image": {
      "label": "Image",
      "required": true,
      "description": "The name of the image in the wiki.",
      "type": "string"
    },
  "date": {
      "label": "Date",
      "required": false,
      "description": "The date in the MM/DD/YYYY format when the screenshot was taken",
      "type": "string" 
    },
  "atmosphere": {
      "label": "Atmosphere",
      "required": true,
      "description": "The type of atmosphere of the planet.",
      "type": "string"
    },
  "tectonics": {
      "label": "Tectonics",
      "required": true,
      "description": "The type of tectonic of the planet.",
      "type": "string"
    },
  "oceans": {
      "label": "Oceans",
      "required": true,
      "description": "The type of oceans of the planet.",
      "type": "string"
    },
  "moons": {
      "label": "Moons",
      "required": true,
      "description": "The number of moons that the planet has.",
      "type": "number"
    },
  "gravity": {
      "label": "Gravity",
      "required": true,
      "description": "The gravity that the planet has.",
      "type": "number"
    },
  "radius": {
      "label": "Radius",
      "required": true,
      "description": "The radius of the planet.",
      "type": "number"
    },
  "hasLife": {
      "label": "Has life?",
      "required": true,
      "description": "Whether the planets has life or not",
      "type": "boolean"
    },
  "description": {
      "label": "Description",
      "required": true,
      "description": "A brief description of the planet",
      "type": "string"
    }
  }
}
</templatedata>
</noinclude>
<includeonly>
<table class="infobox" style="width:22em; background:#f9f9f9; border:1px solid #aaa; padding:4px; float:right; margin:0 0 1em 1em; font-size:90%; text-align:left;">
<table class="infobox" style="width:22em; background:#f9f9f9; border:1px solid #aaa; padding:4px; float:right; margin:0 0 1em 1em; font-size:90%; text-align:left;">
   <tr>
   <tr>
Line 4: Line 96:
   </tr>
   </tr>
   <tr>
   <tr>
     <td>{{#if:{{{image|}}}|[[File:{{{image}}}|200px]]|''No image provided''}}</td>
     <td colspan="2" style="text-align:center;">{{#if:{{{image|}}}|[[File:{{{image}}}|200px]]|''No image provided''}}</td>
   </tr>
   </tr>
<!-- Caption under image -->
<td colspan="2" style="text-align:center; font-size:85%; font-style:italic;">{{#if:{{{date|}}}|Taken at {{{date|}}}|}}</td>
 
 
 
   <tr>
   <tr>
     <td colspan="2" style="text-align:center; font-size:85%; font-style:italic;">
     <td colspan="2"><hr></td>
      Taken at {{{date|Unknown date}}}
    </td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td><b>Atmosphere</b></td>
     <td><b>Atmosphere</b></td>
     <td>{{{atmosphere|Unspecified}}}</td>
     <td>{{{atmosphere|Unspecified}}}</td>
  </tr>
  <tr>
    <td><b>Tectonics</b></td>
    <td>{{{tectonics|Unspecified}}}</td>
  </tr>
  <tr>
    <td><b>Oceans</b></td>
    <td>{{{oceans|Unspecified}}}</td>
 
  </tr>
  <tr>
    <td colspan="2"><hr></td>
  </tr>
  <tr>
    <td><b>Radius</b></td>
    <td>{{{radius|''n''}}}x Earth</td>
  </tr>
<tr>
    <td><b>Gravity</b></td>
    <td>{{{gravity|''n''}}}g</td>
  </tr>
<tr>
    <td><b>Moons</b></td>
    <td>{{{moons|Unspecified}}}</td>
  </tr>
<tr>
    <td colspan="2"><hr></td>
  </tr>
<tr>
    <td><b>Has life:</b></td>
    <td>{{#ifeq:{{{hasLife|}}}|true|Yes|No}}</td>
  </tr>
<tr>
    <td colspan="2"><hr></td>
  </tr>
<tr>
<tr>
    <td colspan = "2" style="text-align: center;"><b>General description:</b><br />{{{description|Unspecified}}}</td>
   </tr>
   </tr>
</table>
</table>
</includeonly>

Latest revision as of 21:06, 20 June 2025

Example


2128-3
Taken at 06/20/25

Atmosphere Martian
Tectonics Continental
Oceans Water

Radius 1x Earth
Gravity 1g
Moons 0

Has life: No

General description:
Small planet, has some interesing buildings near the north pole. Numerous important events in Space Pioneers happened there.


Shows information about a planet

Template parameters[Edit template data]

ParameterDescriptionTypeStatus
Planet IDplanetId

The id of the planet (ssss-i)

Stringrequired
Imageimage

The name of the image in the wiki.

Stringrequired
Datedate

The date in the MM/DD/YYYY format when the screenshot was taken

Stringoptional
Atmosphereatmosphere

The type of atmosphere of the planet.

Stringrequired
Tectonicstectonics

The type of tectonic of the planet.

Stringrequired
Oceansoceans

The type of oceans of the planet.

Stringrequired
Moonsmoons

The number of moons that the planet has.

Numberrequired
Gravitygravity

The gravity that the planet has.

Numberrequired
Radiusradius

The radius of the planet.

Numberrequired
Has life?hasLife

Whether the planets has life or not

Booleanrequired
Descriptiondescription

A brief description of the planet

Stringrequired