teleportxr 1.0.41 → 1.0.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/client/client.js +23 -1
- package/package.json +1 -1
package/client/client.js
CHANGED
|
@@ -125,6 +125,10 @@ class Client {
|
|
|
125
125
|
{
|
|
126
126
|
this.setupCommand=new command.SetupCommand();
|
|
127
127
|
this.clientDynamicLighting=new core.ClientDynamicLighting();
|
|
128
|
+
// Session is (re)starting; the client has zero state, so retract any
|
|
129
|
+
// outstanding ack tracking from a previous session and force a resend.
|
|
130
|
+
this.currentOriginState = new OriginState();
|
|
131
|
+
this.currentLightingState = new LightingState();
|
|
128
132
|
this.setupCommand.float32_draw_distance=10.0;
|
|
129
133
|
if(this.scene)
|
|
130
134
|
{
|
|
@@ -348,7 +352,25 @@ class Client {
|
|
|
348
352
|
var setl =new command.SetLightingCommand();
|
|
349
353
|
setl.uint64_ackId =this.next_ack_id++;
|
|
350
354
|
setl.ClientDynamicLighting_clientDynamicLighting = this.clientDynamicLighting;
|
|
351
|
-
|
|
355
|
+
|
|
356
|
+
// Log in declaration order matching ClientDynamicLighting / SetLightingCommand structs.
|
|
357
|
+
const cdl = setl.ClientDynamicLighting_clientDynamicLighting;
|
|
358
|
+
console.log("\n===== NODE SERVER SENDING SETLIGHTINGCOMMAND =====");
|
|
359
|
+
console.log(JSON.stringify({
|
|
360
|
+
ack_id: setl.uint64_ackId.toString(),
|
|
361
|
+
specularPos: cdl.int2_specularPos,
|
|
362
|
+
specularCubemapSize: cdl.int32_specularCubemapSize,
|
|
363
|
+
specularMips: cdl.int32_specularMips,
|
|
364
|
+
diffusePos: cdl.int2_diffusePos,
|
|
365
|
+
diffuseCubemapSize: cdl.int32_diffuseCubemapSize,
|
|
366
|
+
lightPos: cdl.int2_lightPos,
|
|
367
|
+
lightCubemapSize: cdl.int32_lightCubemapSize,
|
|
368
|
+
specular_cubemap_texture_uid: cdl.uid_specular_cubemap_texture_uid.toString(),
|
|
369
|
+
diffuse_cubemap_texture_uid: cdl.uid_diffuse_cubemap_texture_uid.toString(),
|
|
370
|
+
lightingMode: cdl.LightingMode_lightingMode,
|
|
371
|
+
}, null, 2));
|
|
372
|
+
console.log("===== END SETLIGHTINGCOMMAND =====\n");
|
|
373
|
+
|
|
352
374
|
// This is now the valid origin.
|
|
353
375
|
this.currentLightingState.ackId=setl.uint64_ackId;
|
|
354
376
|
this.currentLightingState.acknowledged=false;
|
package/package.json
CHANGED