From 47ff6403055af12f123ccb373fcbed7e9288b9f6 Mon Sep 17 00:00:00 2001 From: gwigz Date: Sat, 18 Mar 2023 00:06:49 +0000 Subject: [PATCH] Agent properties for rotation --- lib/classes/Agent.ts | 6 ++++-- package-lock.json | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/lib/classes/Agent.ts b/lib/classes/Agent.ts index 75d355b..c3103c6 100644 --- a/lib/classes/Agent.ts +++ b/lib/classes/Agent.ts @@ -63,6 +63,8 @@ export class Agent uiFlags: { 'allowFirstLife'?: boolean } = {}; + headRotation = Quaternion.getIdentity(); + bodyRotation = Quaternion.getIdentity(); cameraLookAt: Vector3 = new Vector3([0.979546, 0.105575, -0.171303]); cameraCenter: Vector3 = new Vector3([199.58, 203.95, 24.304]); cameraLeftAxis: Vector3 = new Vector3([-1.0, 0.0, 0]); @@ -237,8 +239,8 @@ export class Agent agentUpdate.AgentData = { AgentID: this.agentID, SessionID: circuit.sessionID, - HeadRotation: Quaternion.getIdentity(), - BodyRotation: Quaternion.getIdentity(), + HeadRotation: this.headRotation, + BodyRotation: this.bodyRotation, State: AgentState.None, CameraCenter: this.cameraCenter, CameraAtAxis: this.cameraLookAt, diff --git a/package-lock.json b/package-lock.json index 889e54e..685b393 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@caspertech/node-metaverse", - "version": "0.5.40", + "version": "0.5.53", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@caspertech/node-metaverse", - "version": "0.5.40", + "version": "0.5.53", "license": "MIT", "dependencies": { "@caspertech/llsd": "^1.0.5",