Skip to content

format

typescript
Ray.CopyFrom(from)

class: Ray

description

Copy from the specified object to the current object.

parameter

param_nametypedescription
fromRayThe object to copy from.

reture

typedescription
void

code example

typescript
const ray = new Ray(new Vector3(0, 0, 0), new Vector3(0, 0, 1));
const ray2 = new Ray(new Vector3(1, 0, 0), new Vector3(0, 0, 2));
ray.CopyFrom(ray2);