Template:Ent: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Undo-ing the latest edit fixed the random line break issues when using Template:Ent with Template:Fl. Why? How?)
m (this lang template, just somehow,even inside <noinclude> tags, still breaks other pages)
Line 1: Line 1:
<includeonly><code>[[{{{1}}}]]{{#if:{{{2|}}}|&nbsp;{{{2|}}}|}}</code></includeonly>
<includeonly><code>[[{{{1}}}]]{{#if:{{{2|}}}|&nbsp;{{{2|}}}|}}</code></includeonly>
<noinclude>
<noinclude>
{{lang|Template:Ent}}
This template is a faster and cleaner way of marking text as both a link and code. Its primary use is on entity names, but it is used on other things too, such as VMT parameters and console commands.
This template is a faster and cleaner way of marking text as both a link and code. Its primary use is on entity names, but it is used on other things too, such as VMT parameters and console commands.


Line 10: Line 9:
<code><nowiki>{{ent|sv_cheats|1}}</nowiki></code> would give you {{ent|sv_cheats|1}}.
<code><nowiki>{{ent|sv_cheats|1}}</nowiki></code> would give you {{ent|sv_cheats|1}}.
[[Category:Templates]]
[[Category:Templates]]
{{lang|Template:Ent}}
</noinclude>
</noinclude>

Revision as of 00:34, 4 September 2021


This template is a faster and cleaner way of marking text as both a link and code. Its primary use is on entity names, but it is used on other things too, such as VMT parameters and console commands.

The syntax is simple. {{ent|logic_relay}} would return as logic_relay .

Optionally, you can specify a second field of text to not be counted as a link.

{{ent|sv_cheats|1}} would give you sv_cheats 1 .