Problem with Solid Particle System?

Its been a while since I touched BabylonJS but I used to use the SPS and make it that when I clicked a particle it changes color(using its face id).

But now it seems like it always return face id -1? I don’t know why.

Demo: https://playground.babylonjs.com/#2FPT1A#479

It also show this in the console for some reason:

Does it has anything to do with the problem? Maybe I should use a previews version of BabylonJS.

I use these links:

https://preview.babylonjs.com/babylon.js
https://cdn.babylonjs.com/materialsLibrary/babylonjs.materials.min.js
https://cdn.babylonjs.com/proceduralTexturesLibrary/babylonjs.proceduralTextures.min.js
https://preview.babylonjs.com/gltf_validator.js
https://preview.babylonjs.com/loaders/babylonjs.loaders.min.js
https://poolminer.github.io/BabylonTextureCanvas/dist/textureCanvasNoModule.js

Can confirm that there has been a breaking change, compare console results for https://playground.babylonjs.com/#2FPT1A#481 in 5.0 alpha 60 and 4.2

Occurs both in the original scene.onPointerDown function and in the custom scene.onPointerObservable

It seems that some change in picking has affected SPS picking but not mesh picking

This PG https://playground.babylonjs.com/#2FPT1A#482 works in both 5.0 alpha 60 and 4.2

Referenced as bug Change in Picking Created Bug in SPS Picking

1 Like

This will fix the problem with SPS not being pickable:

Regarding your other error it is not related as it occurs in the materials package. Make sure you are using the right version of this package (meaning the same version than the one you use for Babylon.js core) => you should use https://preview.babylonjs.com/materialsLibrary/babylonjs.materials.min.js instead of https://cdn.babylonjs.com/materialsLibrary/babylonjs.materials.min.js. For the procedural texture library, you should use https://preview.babylonjs.com/proceduralTexturesLibrary/babylonjs.proceduralTextures.min.js.

3 Likes