setRotation

Sets the rotation of an object base on given x, y, z values.

setRotation(
	objectName: string,
	position: Vector3,
): Promise<void>
Parameters
Description
Type

objectName

Specifies what object do we want to retrieve the information from.

string

rotation

x, y, z Euler angles of the new rotation.

Usage:

await modelApi.setRotation('Box', {
	x: 90, 
	y: 180, 
	z: 360
});

Last updated