Putting a .VTF file in the hud

Hey guys I made a picture, saved it as a .vtf, and I got an .vmt file which is an UnlitGeneric, (I dont know if thats right.)
And now I want to put the .vtf file ingame, Any help/links that can help me?

Use surface.GetTextureID( path ) to load the texture, then elsewhere in your code draw it. You draw it by using surface.SetTexture( texture_id ), then one of the surface.DrawTexturedRect functions.


local tex = surface.GetTextureID( “hud/healthicon” )

local function HUDPaint( )
surface.SetTexture( tex )
surface.SetDrawColor( 255, 255, 255, 255 )
surface.DrawTexturedRect( 0, 0, ScrW( ), ScrH( ) )

hook.Add( “HUDPaint”, “BigRect.HUDPaint”, HUDPaint )

Which would draw a big rectangle over your whole screen.

`Thanks, got it