Browse Source

Finalized actions Serialization

Tested on all Mansion scene objects, and all Actions Builder scene objects
moreau-mathis 9 năm trước cách đây
mục cha
commit
5d21fea653
2 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 1 1
      src/Actions/babylon.action.ts
  2. 1 1
      src/Actions/babylon.actionManager.ts

+ 1 - 1
src/Actions/babylon.action.ts

@@ -156,7 +156,7 @@
                 targetType: target instanceof Mesh ? "MeshProperties"
                             : target instanceof Light ? "LightProperties"
                             : target instanceof Camera ? "CameraProperties"
-                            : "Scene",
+                            : "SceneProperties",
                 value: target instanceof Scene ? "Scene" : target.name
             }  
         };

+ 1 - 1
src/Actions/babylon.actionManager.ts

@@ -309,7 +309,7 @@
                 };
                 
                 var triggerOptions = this.actions[i].triggerOptions;
-                if (triggerOptions) {   
+                if (triggerOptions && typeof triggerOptions !== "number") {
                     if (triggerOptions.parameter instanceof Node) {
                         triggerObject.properties.push(Action._GetTargetProperty(triggerOptions.parameter));
                     }