ConVar name changes fixes

This commit is contained in:
Fesiug 2023-12-03 23:24:50 -05:00
parent 8d35a71089
commit c1685fd11d
2 changed files with 6 additions and 6 deletions

View File

@ -161,7 +161,7 @@ hook.Add( "PlayerButtonDown", "Benny_PlayerButtonDown_TempForAim", function( ply
local wep = ply:BennyCheck()
if button == KEY_F then
if tobool(ply:GetInfoNum("benny_toggleaim", 0)) then
if tobool(ply:GetInfoNum("benny_wep_toggleaim", 1)) then
wep:SetUserAim( !wep:GetUserAim() )
else
wep:SetUserAim( true )
@ -182,7 +182,7 @@ hook.Add( "PlayerButtonUp", "Benny_PlayerButtonUp_TempForAim", function( ply, bu
local wep = ply:BennyCheck()
if button == KEY_F then
if !tobool(ply:GetInfoNum("benny_toggleaim", 0)) then
if !tobool(ply:GetInfoNum("benny_wep_toggleaim", 0)) then
wep:SetUserAim( false )
end
end

View File

@ -180,13 +180,13 @@ do -- Toolgun
local List = Frame:Add( "DComboBox" )
List:Dock( TOP )
List:SetValue(GetConVar("benny_toolgun"):GetString())
List:SetValue(GetConVar("benny_wep_toolgun"):GetString())
List:DockMargin( 10, 0, 10, 0 )
for i, v in SortedPairs( ToolGunTools ) do
List:AddChoice( i )
end
List.OnSelect = function( self, index, value )
RunConsoleCommand( "benny_toolgun", value )
RunConsoleCommand( "benny_wep_toolgun", value )
Frame:Remove()
end
end
@ -211,7 +211,7 @@ do -- Toolgun
local p = self:GetOwner()
local tr = p:GetEyeTrace()
local tool = p:GetInfo( "benny_toolgun" )
local tool = p:GetInfo( "benny_wep_toolgun" )
if ToolGunTools[tool] then ToolGunTools[tool]( self, p, tr ) end
if CLIENT and IsFirstTimePredicted() then
@ -228,7 +228,7 @@ do -- Toolgun
end,
Custom_Reload = function( self, data )
if CLIENT and self:GetOwner():KeyPressed( IN_RELOAD ) then
if CLIENT then
CreateSelect()
end