Disable Default Ammo HUD?

How would i disable the yellow ammo hud in the bottom right? Thanks.

[lua]function removeammo(name)

for _, v in pairs({"CHudAmmo", "CHudSecondaryAmmo"})do
	if name == v then return false end
end

end
hook.Add(“HUDShouldDraw”, “removeammofunc”, removeammo)[/lua]
Should work.

I wouldn’t recommend using a loop in HUDShouldDraw. It is the difference of taking 15 seconds vs 0.08 seconds of processing time when using loop vs direct-access.

Here’s the correct way with a list of all default huds, and how to add your own: https://dl.dropboxusercontent.com/u/26074909/tutoring/vgui/proper_hud_creation.lua.html

Benchmark: https://dl.dropboxusercontent.com/u/26074909/tutoring/benchmarking_tips/benchmarking_hud_stuff.lua.html