This function can be used to create your own custom matrix and will return an index value for this new matrix which should be stored in a variable for future reference and use. The matrix itself is created as 16 value 1D array where the first 4 elements are row 1, the second 4 elements are row 2 etc... of a 4x4 matrix.NOTE: When you build a new matrix in this way the order of operation is YXZ.
matrix_build(x, y, z, xrotation, yrotation, zrotation, xscale, yscale, zscale);
|x||The x component of the translation vector.|
|y||The y component of the translation vector.|
|z||The z component of the translation vector.|
|xrotation||The angle to rotate around the x-axis (in degrees °).|
|yrotation||The angle to rotate around the y-axis (in degrees °).|
|xzotation||The angle to rotate around the z-axis (in degrees °).|
|xscale||The x scale amount.|
|yscale||The y scale amount.|
|zscale||The z scale amount.|
t_matrix = matrix_build(x, y, 0, 0, 90, 0, 1, 2, 1);
The above code will build a new matrix transform and store the resulting matrix index in the variable "t_matrix".