r/Tf2Scripts • • Sep 13 '20
Answered What's the point of adding custom settings?
I've seen mods that add custom settings, and you can archive aliases with con_logfile, con_filter, and echo, but it's often easier to just set what you want as a setting in your config yourself.
P.S By custom settings, I mean like adding settings options to the advanced options menu.
6
Upvotes
View all comments
Show parent comment
1
u/[deleted] Sep 13 '20 edited Sep 13 '20
When con_logfile is set, echo only emits the string after it, even in the log file, and exec can actually execute log and txt files, so for example, lets say I have a list option for choosing what a fixme bind does. Ideally this would be its entry.
Since the options are actually appended after a space, this would be the result in the log file:
alias fixmebind <option>. con_logfile has to be set then reset after this however, so if there is only one custom option you want to add, simply prepend echo alias, with con_logfile <nameofchoice>.log, keep in mind that the extension can ONLY be log or txt, and Append the default con_logfile variable to the options. The result:If you're gonna have ≥2 options, the log file of choice should be set at the first option, and should be reverted at the last.
Now when you set an option, it should be logged. As for actually updating the custom options, either make another option to execute the log file, or exec at the last option, after con_logfile.
Finally, simply exec the log file at autoexec, and now you have archivable options. For a better example than above, I took my user_default.scr from my config while developing.