This is pretty much the exact setup which it works just fine here in the playground.
You can go into the inspector and change the visibility of the mesh or the alpha of the material (the backplane stuff) and it works just fine.
But in my local scene (which is using all the same BJS scripts as the playground) anytime I set the visibility or the alpha all instances of the plane disappear entirely and will not come back even if I set them back to 1. If I set the mesh that the instances are being created from back to setEnabled(true) then they all come back, but then the I can see the “Master” plane that I am creating the instances from.
Its really really weird behavior that I have never seen before and cant recreate in a PG with the same code oddly enough.
So then I thought… OK hacky workaround leave the plane enabled then stick it off into Narnia and go about my day… BUT NOOOOOOO, still the same behavior except now toggling the enabled on the main plane does not cause them to come back.
I was convinced it would replicated in the PG, but then when it didn’t my mind about blew up.
Nothing I can think of would cause this behavior in Instances ever and I have never seen anything like this.
Logically I dont know what the difference between toggling the master mesh to disabled then to enabled after the visibility is set would make vs keeping it as enabled and setting the visibility…
If I do clones everything is golden, but that is way to many drawcalls now and really instances should work considering they function how expected in the PG.
I guess my workaround is take all of the clones and merge them into a single buffer