Also the context of the command seems slightly mislabelled.
It's not
DrawLine(linex1[i],liney1[i],linex2[i],liney2[i],red,green,blue,alpha,red,green,blue,alpha,thickness)
...but rather:
DrawLine(linex1[i],liney1[i],linex2[i],liney2[i],red,blue,green,alpha,red,blue,green,alpha,thickness)