« Modèle:MetaInfobox/Chantier » : différence entre les versions

De MHWiki
m (Fix affichage si 'ressources' absent)
m (Typos)
Ligne 15 : Ligne 15 :
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Commun|
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Commun|
   <tr>
   <tr>
     <td>'''Plan:'''</td>
     <td>'''Plan :'''</td>
     <td align="left">{{Cliquable|image=item_bplan_c.gif|link=Plans de chantier}}</td>
     <td align="left">{{Cliquable|image=item_bplan_c.gif|link=Plans de chantier}}</td>
   </tr>|}}
   </tr>|}}
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Inhabituel|
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Inhabituel|
   <tr>
   <tr>
     <td>'''Plan:'''</td>
     <td>'''Plan :'''</td>
     <td align="left">{{Cliquable|image=item_bplan_u.gif|link=Plans de chantier}}</td>
     <td align="left">{{Cliquable|image=item_bplan_u.gif|link=Plans de chantier}}</td>
   </tr>|}}
   </tr>|}}
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Rare|
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Rare|
   <tr>
   <tr>
     <td>'''Plan:'''</td>
     <td>'''Plan :'''</td>
     <td align="left">{{Cliquable|image=item_bplan_r.gif|link=Plans de chantier}}</td>
     <td align="left">{{Cliquable|image=item_bplan_r.gif|link=Plans de chantier}}</td>
   </tr>|}}
   </tr>|}}
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Très rare|
   {{#ifeq:{{Data|{{PAGENAME}}|typePlan}}|Très rare|
   <tr>
   <tr>
     <td>'''Plan:'''</td>
     <td>'''Plan :'''</td>
     <td align="left">{{Cliquable|image=item_bplan_e.gif|link=Plans de chantier}}</td>
     <td align="left">{{Cliquable|image=item_bplan_e.gif|link=Plans de chantier}}</td>
   </tr>|}}
   </tr>|}}
Ligne 50 : Ligne 50 :
  {{#if:{{Data|{{PAGENAME}}|ressources}}|
  {{#if:{{Data|{{PAGENAME}}|ressources}}|
  <tr valign="top">
  <tr valign="top">
   <td style="white-space: nowrap; font-weight: bold;">Ressources</td>
   <td style="white-space: nowrap; font-weight: bold;">Ressources :</td>
   <td>{{DataResourceLoop|{{PAGENAME}}|{{Data|{{PAGENAME}}|ressources|0}}}}</td>
   <td>{{DataResourceLoop|{{PAGENAME}}|{{Data|{{PAGENAME}}|ressources|0}}}}</td>
  </tr>|}}
  </tr>|}}

Version du 30 janvier 2024 à 16:23

ÉditerModèle:MetaInfobox/Chantier
Template:MetaInfobox/Buildings
Catégorie Chantiers
Ce Modèle sert à être inclus dans le Modèle MetaInfobox et gère les informations spécifiques aux chantiers.
Évoluable
Temporaire
Chantier parent : Pompe
Plan :
Gain en eau : 70
Défense : 999
Coût : 60
Ressources : Ration d'eau×10 Poutre rafistolée×10 Produits pharmaceutiques×10

Ce modèle n'est fait que pour être utilisé dans le modèle MetaInfobox, dans le quel il sert à afficher les informations spécifiques aux chantiers à partir de leur page Data.