DieAngelMultiClassConfig
From TF2 Wiki
First i am sorry of creating a page for this but it's just too long for the script page
I'm also sorry that it isn't really optimized for ease of configuration, and that i use a lot of bind in aliases, sometimes it is just more convenient.
!UPDATE! I've moved to a bind agnostic version of my configuration system by using auto hotkey, which allow you to bypass the wait restriction some paranoid server admins put in place, all is here: AhkMultiCLass
What does it do (all classes):
- Hitting KP_ENTER will open a menu that allows you to choose which class specific config file you want to load (selection using the numpad 1-9)
- auto reloading after firing and on weapon switching for all the following weapons: all shotguns, soldier's rocket launcher, demoman's grenade launcher, demoman's sticky launcher, medic's needle gun (no reload on switching), sniper's machine gun (no reload on switching)
- numpad 1-9 are bound to usefull and less usefull voice commands (see common_vcom.cfg for details)
- more detailed informations before each class script.
includes.cfg you need to put "exec includes" in your autoexec.cfg for the script to load.
echo "includes.cfg loaded" //filter text con_filter_text "|}" // aliases to toggle console filtering alias "cf1" "con_filter_enable 1" alias "cf0" "con_filter_enable 0" developer 1 cf1 // you can play with the following settings con_notifytime 8 // How long to display recent console text to the upper part of the game window con_nprint_bgalpha 50 // Con_NPrint background alpha. con_nprint_bgborder 5 // Con_NPrint border size. contimes 12 //number of lines alias loader_enable "loader_menu_show; loader_bind; alias config_loader loader_disable" alias loader_disable "clear;loader_unbind; alias config_loader loader_enable" alias config_loader loader_enable alias loader_menu_show "cf0;echo config loader menu:;echo 1. Scout;echo 2. Soldier;echo 3. Pyro;echo 4. Demoman;echo 5. Heavy;echo 6. Tech;echo 7. Medic;echo 8. Sniper;echo 9. Spy;cf1" alias loader_bind "bind KP_END class_scout ;bind KP_DOWNARROW class_soldier;bind KP_PGDN class_pyro ;bind KP_LEFTARROW class_demo ;bind KP_5 class_heavy ;bind KP_RIGHTARROW class_tech ;bind KP_HOME class_medic ;bind KP_UPARROW class_sniper ;bind KP_PGUP class_spy" alias loader_unbind "unbind KP_END ;unbind KP_DOWNARROW ;unbind KP_PGDN ;unbind KP_LEFTARROW ;unbind KP_5 ;unbind KP_RIGHTARROW ;unbind KP_HOME ;unbind KP_UPARROW ;unbind KP_PGUP ;" alias +shoot_reload "+attack;-reload" alias -shoot_reload "-attack;wait 5;+reload;-attack" alias reload_off "bind MOUSE1 +attack;wait 25;-reload" alias reload_on "bind MOUSE1 +shoot_reload" alias attack_reset "bind MOUSE1 +attack" alias default_keys "-attack;bind MOUSE1 +attack;bind MOUSE2 +attack2" alias bind_all "m_wheelup; m_wheeldn; m_mouse2" alias class_scout "loader_disable;exec scout" alias class_sniper "loader_disable;exec sniper" alias class_soldier "loader_disable;exec soldier" alias class_demo "loader_disable;exec demo" alias class_medic "loader_disable;exec medic" alias class_heavy "loader_disable;exec heavy" alias class_pyro "loader_disable;exec pyro" alias class_spy "loader_disable;exec spy" alias class_tech "loader_disable;exec tech" //this is the key to open/close the class selection menu //you need to run the game with -dev -console for the menus to show properly bind KP_ENTER config_loader
disguise-blu.cfg
this file is needed for spy.cfg
//Disguise codes for the blu team bind KP_END "disguise 1 1" bind KP_DOWNARROW "disguise 3 1" bind KP_PGDN "disguise 7 1" bind KP_LEFTARROW "disguise 4 1" bind KP_5 "disguise 6 1" bind KP_RIGHTARROW "disguise 9 1" bind KP_HOME "disguise 5 1" bind KP_UPARROW "disguise 2 1" bind KP_PGUP "disguise 8 1"
disguise-red.cfg
this file is needed for spy.cfg
//Disguise codes for the red team bind KP_END "disguise 1 2" bind KP_DOWNARROW "disguise 3 2" bind KP_PGDN "disguise 7 2" bind KP_LEFTARROW "disguise 4 2" bind KP_5 "disguise 6 2" bind KP_RIGHTARROW "disguise 9 2" bind KP_HOME "disguise 5 2" bind KP_UPARROW "disguise 2 2" bind KP_PGUP "disguise 8 2"
common_vcom.cfg
this file contain the default voice commands for all classes
//offensive talks //flank left bind KP_HOME "voicemenu 0 4" //move up bind KP_UPARROW "voicemenu 0 3" //flank right bind KP_PGUP "voicemenu 0 5" //cheers bind KP_5 "voicemenu 2 2" //battlecry bind KP_LEFTARROW "voicemenu 2 1" //jeers bind KP_RIGHTARROW "voicemenu 2 3" //defensive talks //spy!! bind KP_DOWNARROW "voicemenu 1 1" //sentry ahead bind KP_END "voicemenu 1 2" //incoming bind KP_PGDN "voicemenu 1 0"
demo.cfg (demoman specific config file)
The demoman get the following binds:
- Mouse wheel up: switch to the grenade launcher the first time, and then alternate with the sticky launcher.
- Mouse wheel down: switch to the melee weapon
//DEMOMAN CONFIG///////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias demo_gl "slot1 ;alias demo_switcher demo_pipes; reload_on;+reload" alias demo_pipes "slot2 ;demo_reset; reload_on;+reload" alias demo_bottle "slot3 ;demo_reset; reload_off" alias demo_switcher demo_gl alias demo_reset "alias demo_switcher demo_gl" default_keys reload_on //switch between grenade launcher and sticky launcher bind MWHEELUP demo_switcher bind MWHEELDOWN demo_bottle bind MOUSE2 +attack2 bind MOUSE1 +attack cf0 echo DEMOMAN CONFIG LOADED cf1
heavy.cfg
The heavy get the following binds:
- Mouse wheel up: switch to shotgun
- Mouse wheel down: switch to melee
- Right mouse button: switch to minigun/spin the minigun
//HEAVY CONFIG///////////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias heavy_minigun "slot1 ;bind MOUSE2 +attack2;reload_off" alias heavy_fists "slot3 ;bind MOUSE2 heavy_minigun;reload_off" alias heavy_shotgun "slot2 ;bind MOUSE2 heavy_minigun;reload_on;+reload" default_keys reload_off -reload -attack -attack2 bind MWHEELUP heavy_shotgun bind MWHEELDOWN heavy_fists //mouse2 swap to minigun when it is not at hand, otherwise it spinup the minigun bind MOUSE2 +attack2 bind MOUSE1 +attack cf0 echo HEAVY CONFIG LOADED cf1
medic.cfg (medic config file)
The medic get the following binds:
- Mouse wheel up: switch to the needle gun
- Mouse wheel down: switch to the bone saw
- Right mouse button: switch to the medigun/activate ubercharge
- When holding the medigun, a single click will make the medigun heal constantly, click again to change target or swap weapon to shut it down. (this can eventually cause issue when respawning, simply swap weapon to reset the script)
//MEDIC CONFIG///////////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias medic_healgun "slot2 ;bind MOUSE2 +attack2;bind MOUSE1 medigun_nextarget;-reload" alias medic_bonesaw "slot3 ;bind MOUSE2 medic_healgun;-attack;bind MOUSE1 +attack;reload_off" alias medic_syringe "slot1 ;bind MOUSE2 medic_healgun;-attack;bind MOUSE1 +attack;reload_on" alias medigun_nextarget "-attack;wait 25;+attack" default_keys -reload reload_on bind PGDN "voicemenu 1 7" bind PGUP "dropitem" bind MWHEELUP medic_syringe bind MWHEELDOWN medic_bonesaw bind MOUSE2 medic_healgun bind MOUSE1 +attack cf0 echo MEDIC CONFIG LOADED cf1
pyro.cfg
The pyro get the following binds:
- Mouse wheel up: switch to shotgun.
- Mouse wheel down: switch to the fireaxe.
- Right mouse button: switch between the flamethrower and the shotgun.
//PYRO CONFIG/////////////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias pyro_flame "slot1 ;bind MOUSE2 pyro_shotgun;reload_off" alias pyro_fireaxe "slot3 ;bind MOUSE2 pyro_flame;reload_off" alias pyro_shotgun "slot2 ;bind MOUSE2 pyro_flame;reload_on;+reload" default_keys bind MWHEELUP pyro_shotgun bind MWHEELDOWN pyro_fireaxe //mouse2 will swap back and forth between the flamethrower and the shotgun bind MOUSE2 pyro_shotgun bind MOUSE1 +attack cf0 echo PYRO CONFIG LOADED cf1
scout.cfg
The scout get the following binds:
- Mouse wheel up: switch to pistol.
- Mouse wheel down: switch to the baseball bat.
- Right mouse button: swap between the baseball bat and the scatter gun.
//SCOUT CONFIG////////////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias scout_scattergun "slot1 ;reload_on;alias scout_switcher scout_baseball;+reload" alias scout_baseball "slot3 ;alias scout_switcher scout_scattergun;reload_off" alias scout_pistol "slot2 ;alias scout_switcher scout_scattergun;reload_off" alias scout_switcher scout_baseball default_keys reload_on //alternate between the scatter gun and the previously used weapon bind MOUSE2 scout_switcher //switch to pistol bind MWHEELUP scout_pistol //switch to the baseball bat bind MWHEELDOWN scout_baseball bind MOUSE1 +attack bind PGDN "voicemenu 1 6" bind PGUP "dropitem" cf0 echo SCOUT CONFIG LOADED cf1
sniper.cfg
The sniper get the following binds:
- Mouse wheel up: switch to the machinegun.
- Mouse wheel down: switch to melee weapon.
- Right mouse button: switch to the sniper rifle/zoom in/out.
//SNIPER CONFIG//////////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias sniper_rifle "slot1 ;bind MOUSE2 +attack2;reload_off" alias sniper_machette "slot3 ;bind MOUSE2 sniper_rifle;reload_off" alias sniper_pistol "slot2 ;bind MOUSE2 sniper_rifle;reload_on" default_keys -reload bind MWHEELUP sniper_pistol bind MWHEELDOWN sniper_machette //mouse 2 will switch to the sniper rifle if not currently selected, otherwise, it will zoom bind MOUSE2 +attack2 bind MOUSE1 +attack bind PGDN "voicemenu 1 6" bind PGUP "dropitem" cf0 echo SNIPER CONFIG LOADED cf1
soldier.cfg The soldier get the following binds:
- Mouse wheel up: switch to shotgun.
- Mouse wheel down: switch to the shovel.
- Right mouse button: switch between the shotgun and the rocket launcher.
//SOLDIER CONFIG////////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias soldier_rocket "slot1 ;alias soldier_switcher soldier_shotgun;reload_on;+reload" alias soldier_shovel "slot3 ;alias soldier_switcher soldier_rocket;reload_off" alias soldier_shotgun "slot2 ;alias soldier_switcher soldier_rocket;reload_on;+reload" alias soldier_switcher soldier_prev default_keys reload_on //alternate between the rocket launcher and the previously used weapon bind MOUSE2 soldier_switcher //switch to shotgun bind MWHEELUP soldier_shotgun //switch to shovel bind MWHEELDOWN soldier_shovel bind MOUSE1 +attack bind PGDN "voicemenu 1 6" bind PGUP "dropitem" cf0 echo SOLDIER CONFIG LOADED cf1
spy.cfg
The spy get the following binds:
- Mouse wheel up: switch to the sappers.
- Mouse wheel down: switch to the knife/revolver.
- Right mouse button: cloak/uncloak
- While holding the knife, releasing the left mouse button will trigger automatically last disguise.
- The plus key of the numpad toggle between the disguise configuration for the red or blue team (can't do it automatically)
- Holding the INSERT key of the numpad and then hitting 1-9 will disguise you into the corresponding class in the enemy color.
- Holding the DELETE key of the numpad and then hitting 1-9 will disguise you into the corresponding class in your own team color.
//SPY CONFIG///////////////////////////////////////////////////////////////////////////// loader_unbind exec common_vcom -attack -reload //spy tools & weapons alias spy_zapper "build 4 ;spy_gun_reset ;bind MOUSE1 +attack" alias spy_knife "use tf_weapon_knife ;alias spy_switcher_gun spy_pistol ;spy_tool_reset ;bind MOUSE1 +quickstab" alias spy_pistol "use tf_weapon_revolver ;spy_gun_reset ;spy_tool_reset ;bind MOUSE1 +attack" //alias swapper for the disguises on numpad alias spy_team_blu "alias dsg_enemy "exec disguise-red";alias dsg_ally "exec disguise-blu";exec spy-blu;alias swap_team_disguise spy_team_red; cf0;clear;echo controls set as: BLU TEAM SPY; cf1" alias spy_team_red "alias dsg_enemy "exec disguise-blu";alias dsg_ally "exec disguise-red";exec spy-red;alias swap_team_disguise spy_team_blu; cf0;clear;echo controls set as: RED TEAM SPY; cf1" alias swap_team_disguise spy_team_red alias +disguise_enemy "cf0;clear;echo disguising as enemy...; cf1;dsg_enemy" alias -disguise_enemy "clear;exec common_vcom" alias dsg_enemy "exec disguise-red" alias +disguise_ally "cf0;clear;echo disguising as ally...; cf1;dsg_ally" alias -disguise_ally "clear;exec common_vcom" alias dsg_ally "exec disguise-blu" alias spy_gun_reset "alias spy_switcher_gun spy_knife" alias spy_tool_reset "alias spy_switcher_tools spy_zapper;" alias spy_switcher_gun spy_knife alias spy_switcher_tools spy_zapper alias +quickstab "+attack" alias -quickstab "-attack; lastdisguise" bind MOUSE1 +attack bind MOUSE2 +attack2 bind MWHEELUP spy_zapper bind MWHEELDOWN spy_switcher_gun bind KP_INS +disguise_enemy bind KP_DEL +disguise_ally bind KP_PLUS swap_team_disguise bind PGDN "voicemenu 1 6" bind PGUP "dropitem" cf0 echo SPY CONFIG LOADED cf1
tech.cfg
The Tech get the following binds:
- Mouse wheel up: switch to pistol
- Mouse wheel down: cycle in this order between, wrench, build dispenser, build sentry, build tp entrance, build tp exit.
- Right mouse button: cycle between wrench and shotgun.
//TECH CONFIG///////////////////////////////////////////////////////////////////////////// loader_unbind unbind KP_INS unbind KP_DEL unbind KP_PLUS exec common_vcom -attack -reload alias build0 "build 0" alias build1 "build 1" alias build2 "build 2" alias build3 "build 3" alias tech_build_reset "alias tech_switcher_build tech_spanner" alias tech_gun_reset "alias tech_switcher_gun tech_shotgun" alias tech_spanner "slot3 ;alias tech_switcher_build tech_dispenser ;tech_gun_reset; reload_off" alias tech_dispenser "build0 ;alias tech_switcher_build tech_sentry ;tech_gun_reset; reload_off" alias tech_sentry "build3 ;alias tech_switcher_build tech_tp_in ;tech_gun_reset; reload_off" alias tech_tp_in "build1 ;alias tech_switcher_build tech_tp_out ;tech_gun_reset; reload_off" alias tech_tp_out "build2 ;alias tech_switcher_build tech_spanner ;tech_gun_reset; reload_off" alias tech_switcher_build tech_spanner alias tech_switcher_gun tech_spanner0 alias tech_spanner0 "slot3; alias tech_switcher_build tech_sentry; alias tech_switcher_gun tech_shotgun;reload_off" alias tech_shotgun "slot1; tech_build_reset; alias tech_switcher_gun tech_spanner0;reload_on;+reload" alias tech_pistol "slot2; tech_build_reset; alias tech_switcher_gun tech_shotgun;reload_off" reload_on default_keys bind MWHEELUP tech_pistol //switch between the wrench and all the builds bind MWHEELDOWN tech_switcher_build //switch between wrench and shotgun bind MOUSE2 tech_switcher_gun bind MOUSE1 +attack //quick dismantle bind KP_END "destroy 3" bind KP_PGDN "destroy 0" bind KP_LEFTARROW "destroy 1" bind KP_RIGHTARROW "destroy 2" bind PGDN "voicemenu 1 6" bind PGUP "dropitem" cf0 echo TECH CONFIG LOADED cf1
