Player:DrawViewModel
Description
Show/Hide the player's weapon's viewmodel.
Arguments
Example
Create a ConVar object on the client realm to enable/disable the viewmodel.
local cvarObject = CreateClientConVar("nogun", "1", true, false, "Hide the current viewmodel.") -- Create the ConVar object
hook.Add("HUDPaint", "draw_viewmodel", function()
LocalPlayer():DrawViewModel( cvarObject:GetBool() ) -- Call ConVar:GetBool() inside the parameters of DrawViewModel
end)