diff --git a/gamemodes/zombiesurvival/gamemode/cl_init.lua b/gamemodes/zombiesurvival/gamemode/cl_init.lua index cf234e3..3c883de 100644 --- a/gamemodes/zombiesurvival/gamemode/cl_init.lua +++ b/gamemodes/zombiesurvival/gamemode/cl_init.lua @@ -2240,3 +2240,11 @@ end function PlayMenuCloseSound() MySelf:EmitSound("buttons/lightswitch2.wav", 100, 20) end + +function GM:PlayerBindPress(ply, bind, pressed) + if IsValid( ply ) and ply:Team() == TEAM_UNDEAD and ply:Alive() and not IsFirstTimePredicted() then + if (bind == "impulse 100") then + self:ToggleZombieVision() + end + end +end \ No newline at end of file diff --git a/gamemodes/zombiesurvival/gamemode/cl_postprocess.lua b/gamemodes/zombiesurvival/gamemode/cl_postprocess.lua index 0d07ce9..4813893 100644 --- a/gamemodes/zombiesurvival/gamemode/cl_postprocess.lua +++ b/gamemodes/zombiesurvival/gamemode/cl_postprocess.lua @@ -260,17 +260,6 @@ function GM:ToggleZombieVision(onoff) end end -function GM:PlayerButtonDown( ply, button ) - if not IsFirstTimePredicted() then return end - if not IsValid( ply ) or ply != MySelf then return end - - if ply:Team() == TEAM_UNDEAD and ply:Alive() then - if button == KEY_F then - self:ToggleZombieVision() - end - end -end - local CModWhiteOut = { ["$pp_colour_addr"] = 0, ["$pp_colour_addg"] = 0,