YoYo Games Wiki

draw_line(x1,y1,x2,y2)

From YoYoGames Wiki

Description

This function draws a 1 pixel line from (x1,y1) to (x2,y2).

Arguments

  • x1 (real): horizontal start of the line.
  • y1 (real): vertical start of the line.
  • x2 (real): horizontal end of the line.
  • y2 (real): vertical end of the line.

Explanation

This function draws a 1 pixel line from (x1,y1) to (x2,y2). To draw a horizontal line, both y1 and y2 should be the same number, To draw a vertical line, both x1 and x2 should be the same number.

Remarks

See Also

Content from GMKB, was used to expand this article. The content was contributed by nickydude.