There Should be a util.Light.remove(World)

Started by AGP, November 30, 2011, 06:21:11 AM

Previous topic - Next topic

AGP

One should be able to remove an added light in the same object-oriented fashion as it was created. Right? Disabling seems to be all one can do, as there seems to be no way (object-oriented or otherwise) to actually remove a light.

EgonOlsen

No, there isn't. And there's a reason for this that i explained in some other threads. The solution is to reuse lights, maybe by creating a simple light pool. Such pool can be found in one of these threads as well.
It annoys me too, but i'm not going to change this implementation detail anymore.

AGP


EgonOlsen

Maybe not forever...but for now, it'll stay this way. It's a larger undertaking to change it as it may look and i don't consider it to be that much of a problem even if it is annoying. I prefer adding other stuff in the limited time that there is.