Nikolay Suslov před 6 roky
rodič
revize
ae6a75b77b

+ 15 - 3
public/defaults/proxy/vwf.example.com/aframe/aentity.vwf.yaml

@@ -16,7 +16,11 @@ properties:
         this.positionChanged( position);
       }  
     get: |
-      return this.position || goog.vec.Vec3.create();
+      if (this.position.hasOwnProperty('x')) {
+        return goog.vec.Vec3.createFromValues(this.position.x, this.position.y,  this.position.z);
+      } else {
+        return this.position || goog.vec.Vec3.create();
+      }
   rotation:
     set: |
       var rotation = this.translationFromValue( value ); // parse incoming value
@@ -27,7 +31,11 @@ properties:
         this.rotationChanged( rotation);
       }  
     get: |
-      return this.rotation || goog.vec.Vec3.create();
+      if (this.rotation.hasOwnProperty('x')) {
+        return goog.vec.Vec3.createFromValues(this.rotation.x, this.rotation.y,  this.rotation.z);
+      } else {
+        return this.rotation || goog.vec.Vec3.create();
+      }
   scale:
     set: |
       var scale = this.translationFromValue( value ); // parse incoming value
@@ -38,7 +46,11 @@ properties:
         this.scaleChanged( scale);
       }  
     get: |
-      return this.scale || goog.vec.Vec3.create();
+      if (this.scale.hasOwnProperty('x')) {
+        return goog.vec.Vec3.createFromValues(this.scale.x, this.scale.y, this.scale.z);
+      } else {
+        return this.scale || goog.vec.Vec3.create();
+      }
   clickable:
   displayName:
   visible: