Now you can use the knives from Counter-Strike: Global Offensive as weapons in Garry's Mod!
This is the easiest way to install it and it's recommended for clients.
This will be enabled next time you launch game or server.
This is recommended for servers' owners and those who want to test it before next release.
GarrysMod/garrysmod/addons
folder.or
git clone https://github.com/xDShot/csgo_knives_sweps/
Type these in console or in server config:
Variable name | Default value | Description |
---|---|---|
Bool variables | ||
cl_csgo_knives_lefthanded | 0 | (Clientside) Flip knives viewmodel and hold knives on left hand |
csgo_knives_backstabs | 1 | Allow backstabs |
csgo_knives_canbuy | 1 | Allow buying knives from traitor shop in TTT. May require server restarting if changing |
csgo_knives_decals | 1 | Paint wall decals when hit wall |
csgo_knives_force_ttt | 0 | Forces knives to enable TTT mode. For debug purposes. Normally you shouldn't enable it unless you haven't any trouble getting it work in ttt |
csgo_knives_hiteffect | 1 | Draw effect when hit wall |
csgo_knives_inspecting | 1 | Allow inspecting |
csgo_knives_oldsounds | 0 | Play old sounds when swinging knife or hitting wall |
csgo_knives_primary | 1 | Allow primary attacks |
csgo_knives_secondary | 1 | Allow secondary attacks |
csgo_knives_tfaskins | 1 | Add skins for TFA knives using this pack's base if any of them installed |
Numerical variables | ||
csgo_knives_dmg_prim_back | 90 | How much damage deal when hit with primary attack from behind |
csgo_knives_dmg_prim_front1 | 40 | How much damage deal when firstly hit with primary attack in front or from side |
csgo_knives_dmg_prim_front2 | 25 | How much damage deal when subsequently hit with primary attack in front or from side |
csgo_knives_dmg_sec_back | 180 | How much damage deal when hit with secondary attack from behind |
csgo_knives_dmg_sec_front | 65 | How much damage deal when hit with secondary attack in front or from side |
Pull Requests are welcome. Although there are no strong restrictions in coding style, please make it so it won't be really hard to understand and it won't take any other dependencies. If you make changes into knives, it's better to add them into template and use script to quickly generate code.
Report bugs or suggest new features. Make sure there are no already issue you want to create. When you create it, make it descriptive. Non-descriptive issues like 'it doesn't work plz fix' will be probably ignored and closed.
Lua and tools code are licensed under the MIT license.
Models, sounds and textures are belong to Valve Corporation and other respective creators. The license is currently unknown.
Enjoy! :)