Team Fortress 2
Configs
What is a config?
In VALVE's source games, config files are read and applied throughout your gameplay experience. A great example of configs are control schemes. When you open a source game like Counter Strike or Team Fortress, the control scheme configs are read and applied to the game.
How are configs useful?
Configs are read and run at special times. The primary config, autoexec.cfg, is ran every time a source game opens. Other configs are ran when certain maps or characters are selected. This means that you can make a certain script run when you select a character, and, for example, customize your controls to optimize your play experience with that particular map or character.
My "engineer.cfg"
Unfortunately, I lost my most complicated scripts when I upgraded my OS. Luckily I still have one that I can use as an example. Engineer is a class in TF2 that has special buildings which can complicate controls when in a firefight. I mapped the controls so that he can place his buildings just by holding a button and clicking, instead of going through menus. It makes my gameplay reactions more fluid, giving me a greater edge when I use him. Here's an example of the script:
exec autoexec echo "+-> Thanks for making the script Noltron..." echo "|" echo "+-> execing engineer.cfg..." bind mouse4 destroy_mouse_setup bind mouse5 build_mouse_setup bind mwheelup trigger_happy_s1 bind mwheeldown trigger_happy_s2 bind mouse3 trigger_happy_s3 //special mouse builder/destroyer\\ alias build_mouse_setup "-attack;-attack2;slot4; bind mouse1 build_sentry; bind mouse2 build_dispenser; bind mouse4 build_teleporter_exit; bind mouse5 build_teleporter_entrance" alias build_sentry "build 2;revert" alias build_dispenser "build 0;revert" alias build_teleporter_entrance "build 1;revert" alias build_teleporter_exit "build 3;revert" alias destroy_mouse_setup "-attack;-attack2;slot5; bind mouse1 destroy_sentry; bind mouse2 destroy_dispenser; bind mouse4 destroy_teleporter_exit; bind mouse5 destroy_teleporter_entrance" alias destroy_sentry "destroy 2;revert" alias destroy_dispenser "destroy 0;revert" alias destroy_teleporter_entrance "destroy 1;revert" alias destroy_teleporter_exit "destroy 3;revert" alias revert "bind mouse1 +attack; bind mouse2 +attack2; bind mouse4 destroy_mouse_setup; bind mouse5 build_mouse_setup" alias trigger_happy_s1 "slot0;slot1;revert" alias trigger_happy_s2 "slot0;slot2;revert" alias trigger_happy_s3 "slot0;slot3;revert" echo "|" echo "+-> ...engineer.cfg complete!" //Last updated 7/15/2013 @ 5:50PM
And yes this was last updated 4 and a half years ago. I've updated it but it's since been lost in the void of my formatted harddrive... ;(
Explanation
If you are interested, I'll walk you through it. Essentially, mouse3, mouse4, and mouse5 are all easily accessible buttons on a five-button mouse. Buttons I use for switching items. However, even though the buttons are already used, I customized it by giving each of the buttons two states.
If I hold down a button, it is in "build mode". If I let go of a button, it exits build mode and switches items as usual. So if I enter build mode and left click to activate, it will place a building for me while bypassing all of the build menus. It makes the game a lot quicker, so the benefit is there. I hope you enjoyed my quick blurb about configs!