billboardMode of sourceMesh changes instance rotation

Engine: WebGL2
Version: 8.8.1
Playground: Babylon.js Playground

Steps to reproduce:

  1. Open the playground: Babylon.js Playground
  2. Move camera
  3. Watch the blue box

Expected:
The blue box kept exactly its rotation, and does not change on camera move, like it was cloned.
Expected

Actual:
It somehow “inherited” the billboardMode of sourceMesh, even if instance.billboardMode == 0.
Actual

Related code:

1 Like

Nice one! wanna send a PR?

A quick fix would be adding this._currentLOD !== this._sourceMesh to line 441, like this:

But I’m not sure if this is the real fix.

I like it! This sounds right to me!

1 Like