v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Difference between revisions of "Template:Token"

From Dwarf Fortress Wiki
Jump to navigation Jump to search
(add remaining c* and e* token pages)
(Support for text sets)
 
(27 intermediate revisions by 6 users not shown)
Line 1: Line 1:
<code>{{#if:{{{3|}}}|[<nowiki/>}}[[{{#switch:{{lc:{{#rreplace:{{{2|c}}}|\s|}}}}
+
<includeonly><code>{{#if:{{{3|}}}|[<nowiki/>}}[[{{{link|{{#switch:{{lc:{{{2}}}}}
|ar|armor=Armor
+
|<!-- frequently used pages are placed on top for better performance
|am|ammo=Ammo
+
-->c|cr|creature=Creature token
|bi|biome=Biome
+
|e|ent|entity=Entity token
|bd|bdp|bodydetail|bodydetailplan=Body detail plan
+
|am|ammo=Ammo token
|bo|bod|body=Body
+
|ar|armor=Armor token
|b|bd|bld|build|building=Building
+
|au|audio=Audio
|cm|cman|creaturemannerism|cmannerism|manner|manners|mannerism=Creature mannerism
+
|bi|biome=Biome token
|ct|tx|text|ctext|txt|ctxt|creaturetexture|ctexture|texture=Creature texture
+
|bd|bdp|bodydetail|bodydetailplan=Body detail plan token
|c|cr|creature=Creature
+
|bo|bod|body=Body token
|cv|v|var|cvar|variation|cvariation|creaturevariation=Creature variation
+
|bg|bdg|bodygloss=Bodygloss
|e|ent|entity=Entity
+
|b|bd|bld|build|building=Building token
|et|eth|ethic|ethics=Ethics
+
|cm|cman|creaturemannerism|cmannerism|manner|manners|mannerism=Creature mannerism token
|#default=Unknown
+
|ct|tx|text|ctext|txt|ctxt|ctexture|creaturetexture|texture=Creature texture token
}} token#{{{1|}}}|{{#if:{{{3|}}}||[}}{{{1}}}{{#if:{{{3|}}}|]]:{{{3}}}]|]]]}}</code><noinclude>
+
|cv|v|var|cvar|variation|cvariation|creaturevariation=Creature variation token
==To do==
+
|et|eth|ethic|ethics=Ethic
* Add codes for all pages in [[:Category:DF2012:Tokens]] (that have a list of tokens)
+
|im|imat|imd|imdef|imatdef|inorganic|inorganicmaterial|inorganicmaterialdefinition=Inorganic material definition token
* Add {{tl|text anchor}} to token tables (JS):
+
|in|int|inter|interaction=Interaction token
:<pre style="white-space:pre-wrap">$('#wpTextbox1').val($('#wpTextbox1').val().replace(/\|-\s*\n\|\s*([A-Z_]+)\s*\n/g, function(m, a){return '|-\n| {{text anchor|'+a+'}}\n'}));</pre>
+
|id|idef|itdef|itemdef|item definition=Item definition token
:To check for missed rows:
+
|i|it|item=Item token
:<pre>$('#wikiPreview tr').has('.text-anchor').hide()</pre>
+
|ins|instrument=Instrument token
 
+
|lb|labor=Labor token
==Examples==
+
|la|language=Language token
*{{token|ATTACK|am}} (ammo)
+
|m|mat|material=Material token
*{{token|ARMORLEVEL|ar}} (armor)
+
|md|mdef|matdef|mdefinition|materialdefinition=Material definition token
*{{token|SPEED|c}} (creature)
+
|p|pl|plant=Plant token
*{{token|NAME|c|cat:cats:cat}}
+
|pt|personality|trait|personalitytrait|bf|belief|beliefs|v|vl|value|values=Personality traits, values, and dreams
</noinclude>
+
|po|position=Position token
 +
|r|react|reaction=Reaction
 +
|s|sk|skill=Skill token
 +
|sy|syndrome=Syndrome
 +
|td|tdef|tissue|tdefintion|tissuedefinition=Tissue definition token
 +
|to|tool=Tool token
 +
|tc|trap|trapcomponent=Trap component token
 +
|ts|textset|text|speech=Speech file
 +
|ut|unit|unittype=Unit type token
 +
|wp|weapon=Weapon token
 +
|wo|world=Advanced world generation
 +
|g|gr|graphics=Graphics token
 +
|#default={{token/guess type|{{{1|}}}}}
 +
}}#{{uc:{{{1|}}}}}}}}|{{#if:{{{3|}}}||[}}{{uc:{{{1}}}}}{{#if:{{{3|}}}|]]:{{{3}}}]|]]]}}</code></includeonly><noinclude>
 +
{{documentation}}</noinclude>

Latest revision as of 22:26, 21 December 2024