[SOLVED] Disable node rendering on demand?


Couldn't find this answer, however I suppose it's already been asked :wink:

Is there any built-in mechanism to enable/disable the rendering of a node and its attached nodes?

Like, I have a cloud from which rain is falling (basically, "it's raining from a cloud" would have sounded better), the drops are a particle system. Performance killer. When the cloud is, like, at 50m, the rendering of the particle system should not happen.

I thought, easy, just do this:


Hmm, nothing of such in the Node methods...  :cry:

So before I start suspecting inocent classes, would this have to do something with GameTaskQueue.execute() ?

Clues welcome, thanks...

Ah that's pretty nifty!

Good one, works nicely  :smiley: Thanks for that 8)