Skip to content

Commit

Permalink
Modularize and update CS config for CS2
Browse files Browse the repository at this point in the history
  • Loading branch information
rake5k committed Nov 30, 2023
1 parent c7d8270 commit 4d39c6e
Show file tree
Hide file tree
Showing 8 changed files with 109 additions and 147 deletions.
18 changes: 1 addition & 17 deletions home/users/christian/steam/data/autoexec.cfg
Original file line number Diff line number Diff line change
@@ -1,19 +1,3 @@
alias "+jumpthrow" "+jump; -attack"
alias "-jumpthrow" "-jump"
cl_bobamt_lat "0.1"
cl_bobamt_vert "0.1"
cl_bobcycle "0.1"
cl_showloadout "1"
cl_showpos "1"
cl_updaterate "128"
cl_viewmodel_shift_left_amt "0.5"
cl_viewmodel_shift_right_amt "0.5"
fps_max "300"
host_writeconfig
mp_ignore_round_win_conditions "0"
snd_menumusic_volume "0.050000"
viewmodel_fov "60"
viewmodel_offset_x "-1.5"
viewmodel_offset_y "1"
viewmodel_offset_z "-2"
viewmodel_presetpos "0"
exec myconf
56 changes: 56 additions & 0 deletions home/users/christian/steam/data/binds.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
alias "+use_radar" "+use; cl_radar_always_centered 1; cl_radar_scale 0.8; gameinstructor_enable 1"
alias "-use_radar" "-use; cl_radar_always_centered 0; cl_radar_scale 0.4; gameinstructor_enable 0"
bind "SECTION_SIGN" "toggleconsole"
bind "ALT" "+voicerecord"
bind "DOWNARROW" "buy vest"
bind "LEFTARROW" "buy taser 34"
bind "RIGHTARROW" "buy defuser"
bind "UPARROW" "buy vesthelm"
bind "DEL" "toggle voice_enable"
bind "END" "give weapon_smokegrenade"
bind "HOME" "give weapon_flashbang"
bind "PGUP" "noclip"
bind "KP_0" "buy molotov; buy incgrenade"
bind "KP_1" "buy flashbang"
bind "KP_2" "buy smokegrenade"
bind "KP_3" "buy hegrenade"
bind "KP_4" "buy galilar; buy famas"
bind "KP_5" "buy ak47; buy m4a1"
bind "KP_6" "buy sg556; buy aug"
bind "KP_7" "buy p250"
bind "KP_8" "buy tec9; buy fiveseven"
bind "KP_9" "buy deagle"
bind "KP_DEL" "buy decoy"
bind "KP_ENTER" "buy ssg08"
bind "KP_PLUS" "buy awp"
bind "KP_MINUS" "buy p90"
bind "KP_MULTIPLY" "buy sawedoff; buy mag7"
bind "KP_DIVIDE" "buy nova"
bind "MOUSE3" "player_ping"
# slot1 = Primary
# slot2 = Secondary
# slot3 = Knife
# slot4 = Grenade Cycle
# slot5 = Bomb
# slot6 = HE Grenade
# slot7 = Flashbang
# slot8 = Smoke
# slot9 = Decoy
# slot10 = Molotov / Incendiary
bind "MOUSE4" "slot8; slot7; slot9"
bind "MOUSE5" "slot6; slot10"
bind "b" "buymenu"
bind "c" "radio3"
bind "e" "+use_radar"
bind "g" "drop"
bind "h" "commandmenu"
bind "i" "showbriefing"
bind "j" "cheer"
bind "m" "chooseteam"
bind "n" "nightvision"
bind "o" "buyequip"
bind "t" "use weapon_c4; drop;"
bind "u" "messagemode2"
bind "x" "radio2"
bind "y" "radio1"
bind "z" "+radialradio2"
19 changes: 19 additions & 0 deletions home/users/christian/steam/data/crosshair.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
cl_crosshair_drawoutline "1"
cl_crosshair_dynamic_maxdist_splitratio "0.35"
cl_crosshair_dynamic_splitalpha_innermod "1"
cl_crosshair_dynamic_splitalpha_outermod "0.5"
cl_crosshair_dynamic_splitdist "7"
cl_crosshair_outlinethickness "0.500000"
cl_crosshair_sniper_width "1"
cl_crosshairalpha "255"
cl_crosshaircolor "1"
cl_crosshaircolor_b "50"
cl_crosshaircolor_g "250"
cl_crosshaircolor_r "50"
cl_crosshairdot "0"
cl_crosshairgap "-1.5"
cl_crosshairgap_useweaponvalue "0"
cl_crosshairsize "2.500000"
cl_crosshairstyle "4"
cl_crosshairthickness "0.500000"
cl_crosshairusealpha "1"
3 changes: 3 additions & 0 deletions home/users/christian/steam/data/hud.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
cl_radar_scale "0.350000"
cl_show_clan_in_death_notice "0"
gameinstructor_enable "0"
2 changes: 2 additions & 0 deletions home/users/christian/steam/data/input.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
cl_use_opens_buy_menu "0"
sensitivity "1.000000"
124 changes: 5 additions & 119 deletions home/users/christian/steam/data/myconf.cfg
Original file line number Diff line number Diff line change
@@ -1,119 +1,5 @@
alias "+use_radar" "+use; cl_radar_always_centered 1; cl_radar_scale 0.8; gameinstructor_enable 1"
alias "-use_radar" "-use; cl_radar_always_centered 0; cl_radar_scale 0.4; gameinstructor_enable 0"
bind "/" "toggleconsole"
bind "ALT" "+voicerecord"
bind "DEL" "toggle voice_enable"
bind "DOWNARROW" "buy vest"
bind "END" "give weapon_smokegrenade"
bind "HOME" "give weapon_flashbang"
bind "KP_5" "buy ak47; buy m4a1"
bind "KP_DEL" "buy decoy"
bind "KP_DOWNARROW" "buy smokegrenade"
bind "KP_END" "buy flashbang"
bind "KP_ENTER" "buy ssg08"
bind "KP_HOME" "buy p250"
bind "KP_INS" "buy molotov; buy incgrenade"
bind "KP_LEFTARROW" "buy galilar; buy famas"
bind "KP_MINUS" "buy p90"
bind "KP_MULTIPLY" "buy sawedoff; buy mag7"
bind "KP_PGDN" "buy hegrenade"
bind "KP_PGUP" "buy deagle"
bind "KP_PLUS" "buy awp"
bind "KP_RIGHTARROW" "buy sg556; buy aug"
bind "KP_SLASH" "buy nova"
bind "KP_UPARROW" "buy tec9; buy fiveseven"
bind "LEFTARROW" "buy taser 34"
bind "MOUSE3" "use weapon_smokegrenade; use weapon_flashbang; use weapon_decoy"
bind "MOUSE4" "use weapon_hegrenade; use weapon_incgrenade; use weapon_molotov"
bind "MOUSE5" "+jumpthrow"
bind "PGUP" "noclip"
bind "RIGHTARROW" "buy defuser"
bind "UPARROW" "buy vesthelm"
bind "b" "buymenu"
bind "c" "radio3"
bind "e" "+use_radar"
bind "g" "drop"
bind "h" "commandmenu"
bind "i" "showbriefing"
bind "j" "cheer"
bind "m" "chooseteam"
bind "n" "nightvision"
bind "o" "buyequip"
bind "t" "use weapon_c4; drop;"
bind "u" "messagemode2"
bind "x" "radio2"
bind "y" "radio1"
bind "z" "+radialradio2"
cl_autowepswitch "0"
cl_bobamt_lat "0.1"
cl_bobamt_vert "0.1"
cl_bobcycle "0.1"
cl_cmdrate "128"
cl_crosshair_drawoutline "1"
cl_crosshair_dynamic_maxdist_splitratio "0.35"
cl_crosshair_dynamic_splitalpha_innermod "1"
cl_crosshair_dynamic_splitalpha_outermod "0.5"
cl_crosshair_dynamic_splitdist "7"
cl_crosshair_outlinethickness "0.500000"
cl_crosshair_sniper_width "1"
cl_crosshairalpha "255"
cl_crosshaircolor "1"
cl_crosshaircolor_b "50"
cl_crosshaircolor_g "250"
cl_crosshaircolor_r "50"
cl_crosshairdot "0"
cl_crosshairgap "-1.5"
cl_crosshairgap_useweaponvalue "0"
cl_crosshairsize "2.500000"
cl_crosshairstyle "4"
cl_crosshairthickness "0.500000"
cl_crosshairusealpha "1"
cl_hud_playercount_showcount "0"
cl_interp "0"
cl_interp_ratio "1"
cl_radar_scale "0.350000"
cl_righthand "1"
cl_show_clan_in_death_notice "0"
cl_use_opens_buy_menu "0"
cl_viewmodel_shift_left_amt "0.5"
cl_viewmodel_shift_right_amt "0.5"
gameinstructor_enable "0"
mat_monitorgamma "2.0"
mm_dedicated_search_maxping "50.000000"
net_graphpos "1"
net_graphproportionalfont "0"
rate "128000"
safezonex "0.850000"
sensitivity "1.000000"
snd_deathcamera_volume "0.000000"
snd_duckerattacktime "0.5"
snd_duckerreleasetime "2.5"
snd_duckerthreshold "0.15"
snd_ducking_off "1"
snd_ducktovolume "0.55"
snd_dzmusic_volume "0.2"
snd_hrtf_distance_behind "100"
snd_hrtf_voice_delay "0.1"
snd_hwcompat "0"
snd_mapobjective_volume "0.000000"
snd_menumusic_volume "0.050000"
snd_mix_async "1"
snd_mix_async_onetime_reset "1"
snd_mixahead "0.025"
snd_music_selection "2"
snd_music_volume_onetime_reset_2 "1"
snd_musicvolume_multiplier_inoverlay "0.1"
snd_mute_losefocus "1"
snd_mvp_volume "1.0"
snd_pitchquality "1"
snd_roundend_volume "0.000000"
snd_roundstart_volume "0.000000"
snd_surround_speakers "-1"
snd_tensecondwarning_volume "0.000000"
viewmodel_fov "60"
viewmodel_offset_x "-1.5"
viewmodel_offset_y "1"
viewmodel_offset_z "-2"
voice_enable "1"
volume "1"
zoom_sensitivity_ratio_mouse "0.750000"
exec binds
exec crosshair
exec hud
exec input
exec net
1 change: 1 addition & 0 deletions home/users/christian/steam/data/net.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mm_dedicated_search_maxping 50
33 changes: 22 additions & 11 deletions home/users/christian/steam/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,18 @@ let

cfg = config.custom.users.christian.steam;

mkCfgs = filename:
let
userId = "5051778";
appIds = {
csgo = "730";
};
csgoCfgPath = "Steam/steamapps/common/Counter-Strike Global Offensive/game/csgo/cfg";
in
nameValuePair "${csgoCfgPath}/${filename}.cfg" {
source = ./data/${filename}.cfg;
};

in

{
Expand All @@ -16,16 +28,15 @@ in
};

config = mkIf cfg.enable {
xdg.dataFile =
let
userId = "5051778";
appIds = {
csgo = "730";
};
in
{
"Steam/steamapps/common/Counter-Strike Global Offensive/csgo/cfg/autoexec.cfg".source = ./data/autoexec.cfg;
"Steam/userdata/${userId}/${appIds.csgo}/local/cfg/myconf.cfg".source = ./data/myconf.cfg;
};
xdg.dataFile = listToAttrs (map mkCfgs [
"autoexec"
"binds"
"crosshair"
"hud"
"input"
"myconf"
"net"
]
);
};
}

0 comments on commit 4d39c6e

Please sign in to comment.