Skip to content

Commit b7166bb

Browse files
authored
ESLint correction
1 parent e7cce94 commit b7166bb

1 file changed

Lines changed: 8 additions & 11 deletions

File tree

src/gameobjects/container/ContainerWebGLRenderer.js

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,9 @@ var ContainerWebGLRenderer = function (renderer, container, interpolationPercent
9494
// Set parent values
9595
child.setScrollFactor(childScrollFactorX * scrollFactorX, childScrollFactorY * scrollFactorY);
9696

97-
if(usingQuadAlpha)
97+
if (usingQuadAlpha)
9898
{
99-
if(usingChildQuadAlpha)
99+
if (usingChildQuadAlpha)
100100
{
101101
child.setAlpha(childAlpha * alpha, childAlphaTopRight * alphaTopRight, childAlphaBottomLeft * alphaBottomLeft, childAlphaBottomRight * alphaBottomRight);
102102
}
@@ -105,23 +105,20 @@ var ContainerWebGLRenderer = function (renderer, container, interpolationPercent
105105
child.setAlpha(childAlpha * alpha, childAlpha * alphaTopRight, childAlpha * alphaBottomLeft, childAlpha * alphaBottomRight);
106106
}
107107
}
108+
else if (usingChildQuadAlpha)
109+
{
110+
child.setAlpha(childAlpha * alpha, childAlphaTopRight * alpha, childAlphaBottomLeft * alpha, childAlphaBottomRight * alpha);
111+
}
108112
else
109113
{
110-
if(usingChildQuadAlpha)
111-
{
112-
child.setAlpha(childAlpha * alpha, childAlphaTopRight * alpha, childAlphaBottomLeft * alpha, childAlphaBottomRight * alpha);
113-
}
114-
else
115-
{
116-
child.setAlpha(childAlpha * alpha);
117-
}
114+
child.setAlpha(childAlpha * alpha);
118115
}
119116

120117
// Render
121118
child.renderWebGL(renderer, child, interpolationPercentage, camera, transformMatrix);
122119

123120
// Restore original values
124-
if(usingChildQuadAlpha)
121+
if (usingChildQuadAlpha)
125122
{
126123
child.setAlpha(childAlpha, childAlphaTopRight, childAlphaBottomLeft, childAlphaBottomRight);
127124
}

0 commit comments

Comments
 (0)