Skip to content

Instantly share code, notes, and snippets.

@illixion
Last active March 21, 2025 11:26

Revisions

  1. illixion revised this gist Mar 21, 2025. No changes.
  2. illixion revised this gist Mar 21, 2025. No changes.
  3. illixion created this gist Mar 21, 2025.
    32 changes: 32 additions & 0 deletions game_overrides.cfg
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,32 @@
    // Commands here will run before every class config

    viewmodel_fov 75

    // Movement with null cancel
    bind w +mf
    bind d +mr
    bind a +ml
    bind s +mb

    // Reset keys to default weapon slot behavior without changing viewmodel_fov
    bind "1" "slot1" // Primary weapon
    bind "2" "slot2" // Secondary weapon
    bind "3" "slot3" // Melee weapon

    // Reset mouse wheel behavior
    bind "MWHEELUP" "invprev" // Scroll up to switch to slot 1
    bind "MWHEELDOWN" "invnext" // Scroll down to switch to slot 2
    bind "MOUSE3" "+attack3"

    // Bind for cycling between slot 1 and 2 with Left Shift
    alias "cycle_slots" "slot1_toggle"
    alias "slot1_toggle" "slot1; alias cycle_slots slot2_toggle"
    alias "slot2_toggle" "slot2; alias cycle_slots slot1_toggle"

    bind "SHIFT" "cycle_slots" // Left shift to cycle between slot 1 and 2

    // Viewmodel FOV toggle
    bind "MOUSE5" "incrementvar viewmodel_fov 0.1 75 74.9"

    // Bind MOUSE4 to disguise as last used spy disguise
    bind "MOUSE4" "lastdisguise"
    30 changes: 30 additions & 0 deletions pyro.cfg
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,30 @@
    // Pyro config with hold-to-cycle between slots

    // Weapon slots with viewmodel FOV control
    alias "slot1c" "slot1; viewmodel_fov 0.1; alias next_slot slot2c"
    alias "slot2c" "slot2; viewmodel_fov 75; alias next_slot slot1c"
    alias "slot3c" "slot3; viewmodel_fov 75"

    // Initialize cycle state
    alias "next_slot" "slot2c"

    // Hold-to-cycle system (requires server to allow wait)
    alias "+hold_cycle" "alias _cycle_active cycle_loop; cycle_loop"
    alias "-hold_cycle" "alias _cycle_active"
    alias "cycle_loop" "next_slot; wait 120; _cycle_active"
    alias "cycle_continue" "cycle_loop"

    // Key binds
    bind "MWHEELUP" "slot1c; alias next_slot slot2c"
    bind "MWHEELDOWN" "slot2c; alias next_slot slot1c"
    bind "MOUSE3" "slot3c"
    bind "SHIFT" "+hold_cycle" // Hold to cycle
    bind "MOUSE4" "next_slot" // Single cycle

    // Viewmodel FOV toggle
    bind "MOUSE5" "incrementvar viewmodel_fov 0.1 75 74.9"

    // Number keys with state tracking
    bind "1" "slot1c; alias next_slot slot2c"
    bind "2" "slot2c; alias next_slot slot1c"
    bind "3" "slot3c"