Home
Random
Log in
Settings
About Mango's Lewd Diplomacy: Official Wiki
Disclaimers
Mango's Lewd Diplomacy: Official Wiki
Search
Editing
Template:Building/doc
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
The edit appears to have already been undone.
Anti-spam check. Do
not
fill this in!
<includeonly>{{template doc page transcluded}}</includeonly><noinclude>{{template doc page viewed directly}}</noinclude> <!-- EDIT TEMPLATE DOCUMENTATION BELOW THIS LINE --> This template removes 20px, scaled by defined size, from the left and bottom of building image files and makes the image link to an anchor within [[Buildings]] == Parameters == {| class="wikitable" ! Parameter !! Description !! Required !! Default |- | 1 | Building image file name, not including "Building_" or ".png"<br>Changes dashes - to underscores _ * This parameter can be omitted if using <code>icon</code> ''and'' either <code>3</code> or <code>link</code> | optional || β |- | 2 || Building name, shown in hover text.<br/>'''Sets image size instead if w is not used. Do not use unless used alongside the w parameter.''' || optional || [1] |- | 3 || Building name, shown in hover text. Overrides parameter 2. || optional || [1] |- | w || Image size, with or without px || optional || 78px |- | icon || Alternate image file, not including ".png" || optional || [1] |- | icon type || Replaces "Building" at the start of the file name. Most useful for holdings. || optional || <code>Building</code> |- | link || Sets custom link || optional || <code>[type]#[3]</code> else <code>[type]#[1]</code> |- | type | Sets link page; one of: * <code>cap</code> or <code>capital</code>: [[Planet capital]] * <code>uni</code> or <code>unique</code>: [[Unique buildings]] * <code>com</code> or <code>common</code>: [[Buildings]] * <code>hold</code> or <code>holding</code>: [[Holdings]] <div>Ignored if <code>link</code> is used</div> | optional || [[Buildings]] |- | margin | Additional margin-left applied after initial icon formatting * '''Set only as a number, without "px"''' * Can be a negative value | optional || β |} == Examples == Basic format: <code><nowiki>{{building|image name|size|hover text}}</nowiki></code> Note that the template automatically capitalizes the first letter for default link, but it may be necessary to manually capitalize other parts in order to properly link to a section or anchor. Check also that the link points to an actual building anchor, especially when the icon name does not match the in-game name. {| class="wikitable" ! Wikitext !! Produces |- | <code><nowiki>[[File:Building research lab 1.png]]</nowiki></code> || [[File:Building research lab 1.png]] |- | <code><nowiki>{{building|research lab 1}}</nowiki></code> || {{building|research lab 1}} |- | <code><nowiki>{{building|research lab 1|Research Labs|w=60px}}</nowiki></code> || {{building|research lab 1|Research Labs|w=60px}} |} When linking to buildings that are not on the page [[Buildings]], use the <code>type</code> or <code>link</code> parameters to set the correct page link. {| class="wikitable" ! Wikitext !! Produces |- | <code><nowiki>{{building|embassy|Embassy Complex|w=60px|type=unique}}</nowiki></code> || {{building|embassy|Embassy Complex|w=60px|type=unique}} |- | <code><nowiki>{{building|gaiaseeders 4|Gaia Seeder Outpost|w=60px|type=holding}}</nowiki></code> || {{building|gaiaseeders 4|Gaia Seeder Outpost|w=60px|type=holding}} |} For building icons that do not use "Building" in their file name, the <code>icon</code> or <code>icon type</code> can be used, to either set a custom file or to set a different file prefix. If <code>icon type</code> is set to <code>holding</code>, it will also link to the [[Holdings]] page by default unless overwritten with <code>type</code> parameter. {| class="wikitable" ! Wikitext !! Produces |- | <code><nowiki>{{building|Ministry of Energy|w=60px|type=holding|icon=Holding energy requisitorium}}</nowiki></code> || {{building|Ministry of Energy|w=60px|type=holding|icon=Holding energy requisitorium}} |- | <code><nowiki>{{building|energy requisitorium|Ministry of Energy|w=60px|icon type=holding}}</nowiki></code> || {{building|energy requisitorium|Ministry of Energy|w=60px|icon type=holding}} |}
Summary:
Please note that all contributions to Mango's Lewd Diplomacy: Official Wiki are considered to be released under the Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) (see
Mango's Lewd Diplomacy Official Wiki:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Building
(
edit
)
Template:Template doc page viewed directly
(
edit
)