From Valve Developer Community
Jump to navigation
Jump to search
|
|
Line 1: |
Line 1: |
| {{uselangflags|en=1|zh=1}}<onlyinclude><includeonly>{{inline note|[[File:AltNames.png|10px|link=|alt=]] <!-- | | {{ulf|en=1|zh=1}}<onlyinclude><includeonly>{{inline note|[[File:AltNames.png|10px|link=|alt=]] <!-- |
| -->{{autolang | | -->{{autolang |
| |{{#if: {{{game|}}}|In {{{game}}}, this entity is also tied to |This entity is also tied to }} | | |{{#if: {{{game|}}}|In {{{game}}}, this entity is also tied to |This entity is also tied to }} |
Revision as of 12:10, 6 January 2024

Available doc translations
…
English
This template is intended to be used when multiple entity classnames are tied to single C++ class and they are also usable interchangeably with no or very little side effects, especially those that do not appear to serve any purpose other than deprecation.
Best example of this is prop_physics and physics_prop because physics_prop's classname keyvalue is also fixed-up to prop_physics immediately as it spawns before any classname checks can happen. But prop_physics_override which is also fixed-up shortly after spawning to prop_physics would not be marked as altname because the usage of the entity differs and there are checks in code that allowed it to spawn despite the model not having prop data.
Usage
Parameters
- {{{name1}}} to {{{name8}}} - The alternate classnames.
- {{{misc}}} - Optional: Use to display additional text in the same note.
- {{{suf}}} - Optional: This is a suffix that will be added to all elements of the template to display the content in the desired language (if it is translated into it).
Note:There should be a colon before the language code, for example ":es".
Example
{{altnames|name1=x|name2=y|name3=z}}
would return as:
This template (and its redirect) is
Deprecated. Its use is not recommended and its functionality may be compromised. You can help our editors by replacing or deleting this template on the
Pages that use this template. Once no more pages use this template, it should be
Marked for deletion.
Additional notes:Use #switch parser function instead. Example
{{#switch: {{language}}
| #default = English
| ja = 日本語
| zh-tw = 中文(台灣)
}}
x
This template (and its redirect) is
Deprecated. Its use is not recommended and its functionality may be compromised. You can help our editors by replacing or deleting this template on the
Pages that use this template. Once no more pages use this template, it should be
Marked for deletion.
Additional notes:Use #switch parser function instead. Example
{{#switch: {{language}}
| #default = English
| ja = 日本語
| zh-tw = 中文(台灣)
}}
y
This template (and its redirect) is
Deprecated. Its use is not recommended and its functionality may be compromised. You can help our editors by replacing or deleting this template on the
Pages that use this template. Once no more pages use this template, it should be
Marked for deletion.
Additional notes:Use #switch parser function instead. Example
{{#switch: {{language}}
| #default = English
| ja = 日本語
| zh-tw = 中文(台灣)
}}
z
This template (and its redirect) is
Deprecated. Its use is not recommended and its functionality may be compromised. You can help our editors by replacing or deleting this template on the
Pages that use this template. Once no more pages use this template, it should be
Marked for deletion.
Additional notes:Use #switch parser function instead. Example
{{#switch: {{language}}
| #default = English
| ja = 日本語
| zh-tw = 中文(台灣)
}}
{{altnames|name1=x|game={{game link|portal}}}}
would return as:
This template (and its redirect) is
Deprecated. Its use is not recommended and its functionality may be compromised. You can help our editors by replacing or deleting this template on the
Pages that use this template. Once no more pages use this template, it should be
Marked for deletion.
Additional notes:Use #switch parser function instead. Example
{{#switch: {{language}}
| #default = English
| ja = 日本語
| zh-tw = 中文(台灣)
}}
x
This template (and its redirect) is
Deprecated. Its use is not recommended and its functionality may be compromised. You can help our editors by replacing or deleting this template on the
Pages that use this template. Once no more pages use this template, it should be
Marked for deletion.
Additional notes:Use #switch parser function instead. Example
{{#switch: {{language}}
| #default = English
| ja = 日本語
| zh-tw = 中文(台灣)
}}