Skip to content

Commit 4519584

Browse files
Update BitmapData.shiftHSL, limitValue -> clamp
`math.limitValue` does not exist so it was changed to `math.clamp` which provides the desired functionality.
1 parent c9c8533 commit 4519584

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/gameobjects/BitmapData.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -872,12 +872,12 @@ Phaser.BitmapData.prototype = {
872872

873873
if (s)
874874
{
875-
pixel.s = this.game.math.limitValue(pixel.s + s, 0, 1);
875+
pixel.s = this.game.math.clamp(pixel.s + s, 0, 1);
876876
}
877877

878878
if (l)
879879
{
880-
pixel.l = this.game.math.limitValue(pixel.l + l, 0, 1);
880+
pixel.l = this.game.math.clamp(pixel.l + l, 0, 1);
881881
}
882882

883883
Phaser.Color.HSLtoRGB(pixel.h, pixel.s, pixel.l, pixel);

0 commit comments

Comments
 (0)