• Please make sure you are familiar with the forum rules. You can find them here: https://forums.tripwireinteractive.com/index.php?threads/forum-rules.2334636/

Direct Weapon Binds (no more cycling thru weapon groups)

monsterRed

FNG / Fresh Meat
Jan 7, 2012
1
7
Hi all,

I did a bit of digging and trial/error to get a full weapons list for keybinds. There were lists around, but didn't have the newest weapons. (the single 44 magnum and m4 203 took the freaking longest to find. dual44magum was way more more intuitive than magnum44pistol!)

To bind a specific weapon to a specific key, use the following console command:

set input [desired key] getweapon kfmod.[weapon name]

Example -- If I wanted to bind mp5 medic gun to my "B" key, I'd type the following into the command console:

set input b getweapon kfmod.mp5mmedicgun


Hope this helps y'all streamline your a$$kicking!


MEDIC
mP7mmedicgun
mp5mmedicgun

SUPPORT
shotgun
aa12autoShotgun
boomstick
benellishotgun

SS
single
dualies
deagle
dualdeagal
magnum44pistol
dual44magnum
winchester
crossbow
m14ebrbattlerifle

COMMANDO
ak47assaultrifle
bullpup
m4assaultrifle
scarmk17assaultrifle

ZERKER
knife
axe
chainsaw
katana
machete
claymoresword
chainsaw

Firebug
flamethrower
mac10mp
huskgun

DEMO
law
pipebombexplosive
m32grenadelauncher
m79grenadelauncher
m4203assaultrifle

Tools
syringe
welder
 
Is there any possibility to load another ini file in runtime? (like "exec" command in quake)
There is a way in UT2004 that I remember but not sure if this will work in KF too. Here you go:

Multi-button binds:

E.g:
Alt=exec alt_binds.txt|OnRelease exec def_binds.txt

These are a little more complex... What it does, is executing a .txt file that contains lines of commands, and execute another file that contains another file who should inculde you default binds. That means that you can make a bind for, lets say X, and another bind for Alt+X
You need to make a .txt file containing the binds for Alt+Button and another file for you default binds... like this:

alt_binds.txt:

Code:
set input e speech OTHER 13set input h teamsay <--- I am here!set input l teamsay I take left!set input r teamsay I take right!set input q speech OTHER 12

def_binds.txt:

Code:
set input e Useset input h PlayVehicleHorn 1set input l Taunt throatcutset input r TeamTalkset input q SwitchWeapon 10
NOTE: You can not make complex bindings with this... a complex binding is a bind containing more than one action... like the other binds here!

NOTE2: It is sayd that the more binds executed in one .txt file, the longer screen freezeup... so instead of filling one file with a ****load of binds, try making more button combos... like Shift+Button, Ctrl+Button, Caps+Button, Tap+Button etc..

Here is the site:
[url]http://www.ataricommunity.com/forums/showthread.php?t=408970[/URL]
 
Upvote 0
Is there any possibility to load another ini file in runtime? (like "exec" command in quake)
There is a way in UT2004 that I remember but not sure if this will work in KF too.
Yes, exec command works in KF too. Just tested it for this very purpose; you can put your keybinding commands in a text file in the killingfloor\system folder and run them from the console.
 
Upvote 0
One problem with using exec is that if you do it during a game it is treated as a "cheat" and your perk progress will be disabled (although it seems perk bonuses are still active). If you use it before joining a game this doesn't seem to be a problem.

Another option is to use "indirect" binds, i.e. keybinds that create other keybinds. I have a script file like this:
set input F2 set input 2 switchweapon 2
set input F3 set input 3 switchweapon 3
set input F4 set input 4 switchweapon 4
set input F5 set input 5 switchweapon 5
set input F6 set input 4 Getweapon KFMod.M79GrenadeLauncher
set input F7 set input 4 Getweapon KFMod.FlameThrower
set input F8 set input 3 Getweapon KFMod.SCARMK17AssaultRifle

(The F2-F5 keys are for resetting the default weapon binds.)
 
Upvote 0
Just a note on that, the weapons and items MUST be on its own dedicated key or else only the latest added bind will work and any previous bind will NOT work.

For example I have for 5=getweapon KFMod.syringe | Getweapon KFMod.welder >> You will only be able to pull out the welder and cannot switch to the syringe because you can't - the game won't let you even if you already have it in this the syringe which is always on your unless you're on a custom map/mode...

Here's another: 7=GetWeapon KFMod.knife | GetWeapon KFMod.Axe >> Once you switch over to key 7, you can only pull out the axe and not the knife even if you tap 7 again which *should* bring out the knife, but doesn't....
 
Last edited:
Upvote 0