فهرست منبع

renderingGroupId on instancedMesh has a no-op setter
With a warning (that can be changed :smile:).
This is done since es6 doesn't support setter a getter-only to a public variable in a parent class.
Solving https://github.com/BabylonJS/Babylon.js/issues/3893 .

Raanan Weber 7 سال پیش
والد
کامیت
2cdda3c3bc
1فایلهای تغییر یافته به همراه5 افزوده شده و 0 حذف شده
  1. 5 0
      src/Mesh/babylon.instancedMesh.ts

+ 5 - 0
src/Mesh/babylon.instancedMesh.ts

@@ -58,6 +58,11 @@
             return this._sourceMesh.renderingGroupId;
         }
 
+        public set renderingGroupId(value: number) {
+            //no-op with warning
+            Tools.Warn("Note - setting renderingGroupId of an instanced mesh has no effect on the scene");
+        }
+
         /**
          * Returns the total number of vertices (integer).  
          */