Skip to content

Commit ce66f0a

Browse files
authored
Merge pull request phaserjs#3370 from samme/fix/lights
Fix error when no Light Manager exists
2 parents 935a893 + d7780af commit ce66f0a

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/renderer/webgl/pipelines/ForwardDiffuseLightPipeline.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,11 @@ var ForwardDiffuseLightPipeline = new Class({
7373
{
7474
var lightManager = scene.lights;
7575

76+
if (!lightManager)
77+
{
78+
return this;
79+
}
80+
7681
lightManager.culledLights.length = 0;
7782

7883
if (lightManager.lights.length <= 0 || !lightManager.active)

0 commit comments

Comments
 (0)