scalar_mul

function

scalar_mul(_scalar)

Description

Multiplies every component of the vector with a scalar.

Arguments

Name Type Description
_scalar real Scalar to multiply the vector with.

Returns

vec3 self

Example

vec1 = new Vec3(10, 10, 10);
show_debug_message(vec1.scalar_mul(2)); // Result: { x : 20, y : 20, z: 20 }

Copyright © 2020, eL-Falso. Built on December 14, 2020 using GMDoc.