virtual-world-framework / vwf

Virtual World Framework
https://virtual.wf
Other
142 stars 53 forks source link

Fixed the sceneGetter so that it doesn't set this.scene incorrectly when called on the prototype. #453

Closed kadst43 closed 9 years ago

kadst43 commented 9 years ago

@eric79, @davideaster

David, Eric wanted to run this past you - the if clause that I added is being hit ~10,000 times during initialization. Without the change, this.scene appears to get set to the object that implements sceneGetter, which then makes it impossible to get the actual scene later on. Once initialization is done, the sceneGetter starts working correctly, so this change fixes the problem (and doesn't appear to introduce any new problems - I don't think those 10,000 calls really actually need the scene).

kadst43 commented 9 years ago

@eric79 Good catch! Should be fixed now.

eric79 commented 9 years ago

:+1: