surface.DrawPoly Help

My game is not letting me draw more then 3 points



local function draw_Armor()
	local ply 	 = LocalPlayer()
	local width  = 110
	local height = 16
	local Parmor = ply:Armor() + 50
	local hp 	 = ply:Health()
	local color  = Color(255,255,255)
	local size 	 = 100
	local bar 	 = 100

	if hp >= 100 then 
		bar = 100
	elseif GAMEMODE.round_state == ROUND_PREP then
		bar = 100
	else
		bar = ( 20 + ( hp / 2 ) + ( Parmor / 2 ) ) 
	end

	if ply:GetRole() == ROLE_INNOCENT then
		color = Color( 180, 188, 132 )
	elseif ply:GetRole() == ROLE_TRAITOR then
		color = Color( 255, 0, 0 )
	end
	
	if bar > 100 then
		bar = 100
	end
   
	local box = {
		{ x = 250, 	  	y = ScrH() - 10 },
		{ x = 250,	  	y = ScrH() - 25 }, 
		{ x = bar + 250, y = ScrH() - 10 },
		{ x = bar + 250,	y = ScrH() - 25 },
	}
	
	surface.SetDrawColor( color )
	draw.NoTexture()
	surface.DrawPoly( box )
	
	--[[
	surface.DrawRect(x, y, width, height)
	surface.DrawRect(x, y, width, height)
	surface.DrawRect(x, y, width, height)
	surface.DrawRect(x, y, width, height)
	]]-- 
end


Yes the function is called

You have to draw a complete, direct, closed loop. It looks like your last two values are mismatched in order.

[editline]8th September 2016[/editline]

You don’t want the vectors crossing. It should be direct usually from left to right

Thanks Man
#include <iostream>
int main()
{
std::cout << “U DE BEST” << std::endl;
return 0;
}