add_new

function

add_new(_vector)

Description

Adds the specified vector to this vector.

Arguments

Name Type Description
_vector vec3 The vector being added.

Returns

vec3 Result of the addition in new vector.

Example

vec1 = new Vec3(10, 10, 10);
vec2 = new Vec3(8, 6, 9);
vec3 = vec1.add_new(vec2);
show_debug_message(vec1); // Result: { x : 10, y : 10, z : 10 }
show_debug_message(vec3);  // Result: { x : 18, y : 16, z : 19 }

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