I dont get this error

so im working on an addon and i dont get what this error means



[ERROR] lua/includes/util/color.lua:16: bad argument #1 to 'min' (number expected, got nil)
  1. min - [C]:-1
   2. Color - lua/includes/util/color.lua:16
    3. unknown - addons/admin-report/lua/autorun/cl_adminreport.lua:36


this is in the config



BoxColorAR = 0, 160, 255 -- The default color was 0, 160, 255


and this is in the Client file



		function Frame:Paint ( w, h )
			draw.RoundedBox( 4, 0, 0, w, h, Color(BoxColorAR))
		end


Please help! <3 , and facepunch if i posted in wrong section please dont ban me! <3

I think you are setting the value BoxColorAR with 3 different values.
You can do that if you are doing like



r, g, b = 0, 160, 255


And it will set all the numbers.
But you did:

BoxColorAR = 0 ->
BoxColorAR = 160 ->
BoxColorAR = 255.

So what you put in to the Color() is 255 but it needs atleast 3 values.

You could do



BoxColorAR = Color( 0, 160, 255 )


and then change the Frame:Paint to



function Frame:Paint ( w, h )
	draw.RoundedBox( 4, 0, 0, w, h, BoxColorAR)
end


I only changed there the Color(BoxColorAR) -> BoxColorAR.

Thanks! Love from Sweden