Crosshair code request.

So I am testing some things in Single Player and one of them is to code a crosshair. I was hoping to have some examples to go off of. So post any here if you have any, thank you.


(User was banned for this post ("Wrong section" - mahalis))

From the wiki, **[Surface.DrawLine

http://wiki.garrysmod.com/favicon.ico](http://wiki.garrysmod.com/?title=Surface.DrawLine)**
[lua]hook.Add( “HUDPaint”, “Circle”, function()
local center = Vector( ScrW() / 2, ScrH() / 2, 0 )
local scale = Vector( 100, 100, 0 )
local segmentdist = 360 / ( 2 * math.pi * math.max( scale.x, scale.y ) / 2 )
surface.SetDrawColor( 255, 0, 0, 255 )

for a = 0, 360 - segmentdist, segmentdist do
	surface.DrawLine( center.x + math.cos( math.rad( a ) ) * scale.x, center.y - math.sin( math.rad( a ) ) * scale.y, center.x + math.cos( math.rad( a + segmentdist ) ) * scale.x, center.y - math.sin( math.rad( a + segmentdist ) ) * scale.y )
end

end )[/lua]

Thanks, appreciate it.

Edit: How do I change the shape to something different than a circle?