Hi Gabby,
Below code is working in cesium portal.
But if i take it offline, then it is throwing an error :
"Uncaught TypeError: Cannot read property 'addEventListener' of undefined"
Code :
viewer.scene.preUpdate.addEventListener(function(scene, time) {
particleSystem.modelMatrix = computeModelMatrix(entity, time);
// Account for any changes to the emitter model matrix.
// particleSystem.emitterModelMatrix = computeEmitterModelMatrix();
// Spin the emitter if enabled.
if (viewModel.spin) {
viewModel.heading += 1.0;
viewModel.pitch += 1.0;
viewModel.roll += 1.0;
}
});
Please help