```
/// @func draw_line_ext(x1, y1, x2, y2, color1, alpha1, width1, color2, alpha2, width2)
/// @desc Draws a line with custom widths, colors, and alphas.
/// @param {real} x1 starting x-pos
/// @param {real} y1 starting y-pos
/// @param {real} x2 ending x-pos
/// @param {real} y2 ending y-pos
/// @param {real} color1 starting color
/// @param {real} alpha1 starting alpha
/// @param {real} width1 starting width
/// @param {real} color2 ending color
/// @param {real} alpha2 ending alpha
/// @param {real} width2 ending width
/// @returns {undefined}
var x1 = argument0,
x2 = argument2,
y1 = argument1,
y2 = argument3,
c1 = argument4,
c2 = argument7,
a1 = argument5,
a2 = argument8,
w1 = argument6,
w2 = argument9;
// Save the old world matrix:
var _mat_world = matrix_get(matrix_world);
// Build a matrix to rotate our line to point in the correct direction:
matrix_set(matrix_world, matrix_build(x1, y1, 0, 0, 0, point_direction(x1, y1, x2, y2), 1, 1, 1));
// Build our line out of triangles and draw:
draw_primitive_begin(pr_trianglestrip);
draw_vertex_color(0, -w1 / 2, c1, a1);
draw_vertex_color(x2 - x1, -w2 / 2, c2, a2);
draw_vertex_color(0, w1 / 2, c1, a1);
draw_vertex_color(x2 - x1, w2 / 2, c2, a2);
draw_primitive_end();
// Reset the old matrix:
matrix_set(matrix_world, _mat_world);
return undefined;
```