Skip to content

Commit 8cd45a7

Browse files
committed
ESLint fixes
1 parent ec570a6 commit 8cd45a7

5 files changed

Lines changed: 11 additions & 8 deletions

File tree

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949

5050
### Updates
5151

52-
* The `backgroundColor` property of the Game Config is now used to set the CSS backgroundColor property of the game Canvas element. This avoids a `fillRect` call in Canvas mode and allows for 'punch through' effects to be created. If `transparent` is true, the CSS property is not set.
52+
* The `backgroundColor` property of the Game Config is now used to set the CSS backgroundColor property of the game Canvas element. This avoids a `fillRect` call in Canvas mode and allows for 'punch through' effects to be created. If `transparent` is true, the CSS property is not set and no background color is drawn in either WebGL or Canvas, allowing the canvas to be fully transparent.
5353
* You can now modify `this.physics.world.debugGraphic.defaultStrokeWidth` to set the stroke width of any debug drawn body, previously it was always 1 (thanks @samme)
5454
* `TextStyle.setFont` has a new optional argument `updateText` which will sets if the text should be automatically updated or not (thanks @DotTheGreat)
5555
* `ProcessQueue.destroy` now sets the internal `toProcess` counter to zero.
@@ -87,7 +87,7 @@
8787
* When using a Particle Emitter, the array of dead particles (`this.dead`) wasn't being filled correctly. Dead particles are now moved to it as they should be (thanks @Waclaw-I)
8888
* The `PathFollower.startFollow` method now properly uses the `startAt` argument to the method, so you can start a follower off at any point along the path. Fix #3688 (thanks @DannyT @diteix)
8989
* Static Circular Arcade Physics Bodies now render as circles in the debug display, instead of showing their rectangle bounds (thanks @maikthomas)
90-
* Changing the mute flag on an `HTML5AudioSound` instance, via the `mute` setter, now works, as it does via the Sound Manager (thanks @Waclaw-I)
90+
* Changing the mute flag on an `HTML5AudioSound` instance, via the `mute` setter, now works, as it does via the Sound Manager (thanks @Waclaw-I @neon-dev)
9191
* Changing the volume on an `HTML5AudioSound` instance, via the `volume` setter, now works, as it does via the Sound Manager (thanks @Waclaw-I)
9292

9393
### Examples and TypeScript

src/gameobjects/extern/Extern.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,16 @@ var Extern = new Class({
6161
GameObject.call(this, scene, 'Extern');
6262
},
6363

64-
preUpdate: function (time, delta)
64+
preUpdate: function ()
6565
{
6666
// override this!
67+
// Arguments: time, delta
6768
},
6869

69-
render: function (renderer, camera, calcMatrix)
70+
render: function ()
7071
{
7172
// override this!
73+
// Arguments: renderer, camera, calcMatrix
7274
}
7375

7476
});

src/physics/arcade/PhysicsGroup.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ var PhysicsGroup = new Class({
127127
config = {
128128
createCallback: this.createCallbackHandler,
129129
removeCallback: this.removeCallbackHandler
130-
}
130+
};
131131
}
132132

133133
/**

src/renderer/webgl/WebGLRenderer.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ var WebGLRenderer = new Class({
6262
var gameConfig = game.config;
6363

6464
var contextCreationConfig = {
65-
alpha: true,
65+
alpha: gameConfig.transparent,
6666
depth: false,
6767
antialias: gameConfig.antialias,
6868
premultipliedAlpha: gameConfig.premultipliedAlpha,
@@ -556,7 +556,7 @@ var WebGLRenderer = new Class({
556556

557557
gl.enable(gl.BLEND);
558558

559-
// gl.clearColor(clearColor.redGL, clearColor.greenGL, clearColor.blueGL, 1);
559+
gl.clearColor(clearColor.redGL, clearColor.greenGL, clearColor.blueGL, 1);
560560

561561
// Initialize all textures to null
562562
for (var index = 0; index < this.currentTextures.length; ++index)

src/tweens/tween/Tween.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1209,7 +1209,8 @@ var Tween = new Class({
12091209
break;
12101210
}
12111211

1212-
if (!tweenData.elapsed && tweenData.current) {
1212+
if (!tweenData.elapsed && tweenData.current)
1213+
{
12131214
tweenData.elapsed = tweenData.duration * tweenData.current;
12141215
}
12151216

0 commit comments

Comments
 (0)