autoexec.cfg

// CS2 marus exec
echo "loading exec...."

// Shortcuts for console commands
echo "loading shortcuts..."
alias "d" "disconnect"
alias "q" "quit"
alias "s" "status"
alias "rs" "mp_restartgame 1"
alias "v1" "voice_modenable 1"
alias "v0" "voice_modenable 0"


// General =================================================
echo "loading general..."
fps_max "400"											//Frame rate limiter. 0=no limit. Does not apply to dedicated server.
cl_join_advertise "2"									// Advertise joinable game in progress to Steam friends, 
														// otherwise need a Steam invite 
														// (2: all servers, 1: official servers, 0: none)
cl_showfps 1
cq_netgraph 0 // <--- bad

// Viewmodel ===============================================
echo "loading viewmodel..."
viewmodel_fov 69;
viewmodel_offset_y 3;
viewmodel_offset_x 3;
viewmodel_offset_z -3;
viewmodel_presetpos "1"

// TODO: not implemented in cs2 yet
// viewmodel_recoil "1.0"

// shooting / running bob


// Crosshair ===============================================
echo "loading crosshair..."
cl_crosshair_drawoutline "0"
cl_crosshair_dynamic_maxdist_splitratio "0.300000"
cl_crosshair_dynamic_splitalpha_innermod "1"
cl_crosshair_dynamic_splitalpha_outermod "0.5"
cl_crosshair_dynamic_splitdist "7"
cl_crosshair_friendly_warning "0"
cl_crosshair_outlinethickness "1"
cl_crosshair_sniper_show_normal_inaccuracy "0"
cl_crosshair_sniper_width "1"
cl_crosshair_t "0"
cl_crosshairalpha "255"
cl_crosshaircolor "1"
cl_crosshaircolor_b "50"
cl_crosshaircolor_g "250"
cl_crosshaircolor_r "50"
cl_crosshairdot "0"
cl_crosshairgap "-2.276113"
cl_crosshairgap_useweaponvalue "0"
cl_crosshairsize "1.954757"
cl_crosshairstyle "4"
cl_crosshairthickness "0.293840"
cl_crosshairusealpha "1"


// normal crosshair
alias "normal_crosshair" "cl_crosshairsize 1.954757"

// util crosshair
alias "big_crosshair" "cl_crosshairsize 1000"

// server / interp settings
// echo "overloading setting update rate and interp"
// REMOVED by VALVE
// cl_updaterate 128
// cl_interp_ratio 1
// cl_interp "0.015625"

// video settings
echo "changing video settings"
r_fullscreen_gamma 2.2

// Custom Binds ============================================
// risky for now
// unbindall

// basic binds ---
echo "loading basic binds..."
bind "1" "slot1"
bind "2" "slot2"
bind "3" "slot3"
bind "4" "slot4;+lookatweapon;-lookatweapon"
bind "5" "slot5;+lookatweapon;-lookatweapon"

// movement

bind "ENTER" "+attack"
bind "LEFTARROW" "+turnleft"
bind "RIGHTARROW" "+turnright"
bind "UPARROW" "+forward"
bind "DOWNARROW" "+back"

// ----------------------------------------------------------------
echo "loading SPUNJ movement config..."

alias "_checkw" "-forward; alias checkw"
alias "+w" "+forward; alias checkw _checkw"
alias "-w" "checkw"
bind "w" "+w"

alias "_checks" "-back; alias checks"
alias "+s" "+back; alias checks _checks"
alias "-s" "checks"
bind "s" "+s"

alias "_checka" "-left; alias checka"
alias "+a" "+left; alias checka _checka"
alias "-a" "checka"
bind "a" "+a"

alias "_checkd" "-right; alias checkd"
alias "+d" "+right; alias checkd _checkd"
alias "-d" "checkd"
bind "d" "+d"

alias "_checkcrouch" "-duck; alias checkcrouch"
alias "+crouch" "+duck; alias checkcrouch _checkcrouch"
alias "-crouch" "checkcrouch"
bind "ctrl" "+crouch"

alias "_checkwalk" "-sprint; alias checkwalk"
alias "+walk" "+sprint; alias checkwalk _checkwalk"
alias "-walk" "checkwalk"
bind "shift" "+walk"

// ----------------------------------------------------------------

// MISC
echo "loading misc..."
bind "b" "buymenu"
bind "e" "+use"
bind "g" "drop"
bind "i" "show_loadout_toggle"
bind "m" "teammenu"
bind "r" "+reload; -attack; -attack2"
bind "t" "+spray_menu" // graphitti
bind "`" "toggleconsole"
bind "TAB" "+showscores"
bind "ESCAPE" "cancelselect"
bind "DEL" "mute"
bind "PAUSE" "pause"
bind "ENTER" "+attack"
bind "CAPSLOCK" "toggle cl_radar_scale 0.571869 1"

// f keys
echo "loading f keys..."
bind "F1" "slot10"
bind "F3" "autobuy"
bind "F4" "rebuy"
bind "F5" "jpeg"
bind "F6" "save quick"
bind "F7" "load quick"
bind "F10" "quit prompt"

// mouse
echo "loading mouse..."
bind "MOUSE1" "+attack"
bind "MOUSE2" "+attack2"
bind "MOUSE3" "player_ping"
bind "MWHEELDOWN" "invnext"

// chat
echo "loading chat binds..."
bind "y" "messagemode"
bind "u" "messagemode2"

// buying with numpad
bind "kp_2" " buy vesthelm; buy vest;"
bind "kp_8" "buy awp;"

// not using others for now ----------------------------------------
// bind "kp_home" "buy m4a1; buy ak47;"
// bind "kp_pgup" "buy galilar; buy famas;"
// bind "kp_slash" "buy ssg08;"
// bind "kp_leftarrow" "buy p250;"
// bind "kp_5" "buy tec9; buy fiveseven;"
// bind "kp_rightarrow" "buy deagle; buy revolver;"
// 
// bind "kp_pgdn" " buy defuser;"
// bind "kp_del" " buy flashbang;"
// bind "kp_ins" " buy smokegrenade;"
// bind "kp_end" " buy molotov; buy incgrenade;"
// bind "kp_plus" " buy hegrenade;"

// cleaning blood --------------------------------------------------
// TODO: Unknown command: r_cleardecals not implemented in cs2
// bind "shift" "+speed; r_cleardecals";

// JUMPING       ---------------------------------------------------
echo "loading jumping..."
bind "mwheelup" "+jump";

alias +duckjump "+jump; +duck"; 
alias -duckjump "-jump; -duck";
bind "SPACE" "+duckjump";

// TODO: not implemented in cs2
// bindtoggle "MOUSE5" cl_righthand;

// jumpthrow cs2 ----------------------------------------------------
echo "loading jumpthrows binds..."

// jump throw
alias "+jumpaction" "+jump;"
alias "+throwaction" "-attack; -attack2"
alias "-jumpaction" "-jump"
bind alt "+jumpaction;+throwaction;"

// run throw
alias "+runthrow" "+forward;+jump;"
alias "-runthrow" "-jump;-forward"
bind n "+runthrow;+throwaction"


// -----------------------------------------------------
// Primary / secondary buttons
echo "loading primary / alternative buttons..."

// Part 0 => what is being used:
// -------------------------
// Key => Primary; Secondary
// -------------------------
// Q => Molotov; Nade
// C => Flashbang; Smoke
// Z => Inspect; noclip
// X => normal crosshair; smoke crosshair
// F => Speak; Clean Utility
// V => jumpthrow; Rethrow Last Nade
// P => radialradio; enter warmup mode
// -------------------------


// Part 1 => primary keys / definition

// primary aliases
alias "molly_adhd" "slot10;+lookatweapon;-lookatweapon"
alias "flash_adhd" "slot7;+lookatweapon;-lookatweapon"
alias "smoke_adhd" "slot8;+lookatweapon;-lookatweapon"
alias "nade_adhd" "slot6;+lookatweapon;-lookatweapon"

// PRIMARY: 
alias defQ		"bind q molly_adhd"
alias defC		"bind c flash_adhd"
alias defZ		"bind z +lookatweapon"
alias defX		"bind x normal_crosshair"
alias defF		"bind f +voicerecord"
alias defV      "bind v +radialradio3"
alias defP		"bind p say gg"

// Part 2 => secondary command definitions (make sure its the same letters)
// Hold down a toggle key to trigger a secondary command
alias keyQ		"bind q customQ"
alias keyC		"bind c customC"
alias keyZ		"bind z customZ"
alias keyX		"bind x customX"
alias keyF		"bind f customF"
alias keyV		"bind v customV"
alias keyP		"bind p customP"

// Part 3 => secondary commands

alias customQ	"nade_adhd"
alias customC	"smoke_adhd"
alias customZ	"noclip"
alias customX   "big_crosshair"
alias customF	"ent_fire smokegrenade_projectile kill;ent_fire molotov_projectile kill;ent_fire flashbang_projectile kill;ent_fire hegrenade_projectile kill;ent_fire decoy_projectile kill;stopsound;say .clear" 
alias customV   "sv_rethrow_last_grenade; say .rethrow"
alias customP	"sv_grenade_trajectory_prac_pipreview 1; sv_grenade_trajectory_prac_trailtime 4; mp_buy_anywhere 1; mp_freezetime 0; mp_ignore_round_win_conditions 1; mp_buytime 99999; mp_startmoney 60000; mp_maxmoney 60000; ; ammo_grenade_limit_total 6; mp_warmup_pausetimer 1; mp_warmup_start; sv_cheats 1; sv_infinite_ammo 2; bot_kick; say Practice Enabled" // practice mode

//Part 4 => secondary command switcher logic 
alias +secondarycommand "keyQ; keyC; keyZ; keyX; keyC; keyF; keyV; keyP"
alias -secondarycommand "defQ; defC; defZ; defX; defC; defF; defV; defP"
bind mouse4 +secondarycommand

// -----------------------------------------------------

// CS2 marus exec
echo "lesgooooooooooooo"