Template talk:Console command

From Valve Developer Community
Jump to: navigation, search
Icon-message-48px.png
Welcome to Template talk:Console command!
This is the start of the Console command discussion page.

To add a new message, click on "Add Topic/Reply" button below, and set the "Subject".
To add a Reply, do the same as above, but leave the "Subject" blank.

Moving to {{entity}}

ERR
Empty.png
Pee18:39, 15 August 2023 (UTC)
Should we continue to use this template, or modify {{entity}} to categorize and change the titles, with some modifications, such as the equivelant of Category:Source Base Entities being Category:Console commands, and changing the title to be lowercase and with underscores, but not embed it within {{code}}? (the same would apply to {{console variable}}.) I'm leaning towards the latter.
ERR
UserAvatarFrame-Equalizer5118.png
Equalizer11:44, 15 August 2023 (UTC−7)
I changed the title to use {{code}} to be more uniform with Entity. I would be open to merging the two templates, however that might just cause a spaghetti code situation. If we combine this and entity, then we will likely have to combine {{Shader}} and the likes as well
ERR
UserAvatarFrame-Equalizer5118.png
Equalizer11:45, 15 August 2023 (UTC−7)(edited)
I also think that plain text with underscores look ugly. I prefer sv_cheats over sv_cheats as monospace text looks more uniform
ERR
Empty.png
Pee18:57, 15 August 2023 (UTC)(edited)
My main point was mentioning a few possible changes that could be made, not necessarily whether or not it's in code (though i do think it shouldn't be in code). As for a spaghetti template, something like this might work fairly well (maybe even with changing the name of the name of the base page):
Template:entity
{{#switch: {{{type|}}} |#default={{error|Missing required argument "type"}} |e0|e1|e2|e3|e4|e5={{entity/entity|whatever|arguments|are|necessary|to|pass}} |convar|command={{entity/console|whatever|arguments|are|necessary|to|pass}} |c0={{entity/qc|whatever|arguments|are|necessary|to|pass}} }}
I suppose it would also make sense to instead simply make this template more like {{entity}}, adding things like a sentence and game categorization.

Alternatively, an internal, more basic template handling things like categories, titles, and the text based off it (the internal templates) parameters could be managed by an external template doing the heavy lifting (such as autolang and types to input the right strings and categories to the internal templates) might work. This would more or less be the same as my earlier example of my example of the template, but with only one internal template instead of 3.

ERR
UserAvatarFrame-Equalizer5118.png
Equalizer12:35, 15 August 2023 (UTC−7)
That's a good idea, however I don't think that that would be efficient. Entity already has the appropriate functionality that we need for what you are describing, in terms of the type parameter. We can have better organization by just taking the existing entity template and editing it. See User:Equalizer5118/Format Template Proposition
ERR
Empty.png
Pee20:07, 15 August 2023 (UTC)
That's probably the best call. We should also probably only really use a single (or very few) {{autolang}} templates per type, so the redundancy is within the switches, so it's more navigable (the switches this way could be on the same line more easily).