Closed
Description
Version
- Phaser Version: 3.50
Description
When using the Light Pipeline (Light2D) tintFill
appears to be doing the same thing as a regular tint
call.
Example Test Code
Check out this labs example for the non-lights behavior: http://labs.phaser.io/view.html?src=src\display\tint\tint%20fill%20effect.js
Change it to something like this and the two will look the same
class Example extends Phaser.Scene
{
constructor ()
{
super();
}
preload ()
{
this.load.image('mushroom', 'assets/particles/glass.png');
}
create ()
{
this.add.image(200, 300, 'mushroom').setPipeline("Light2D");
this.add.image(400, 300, 'mushroom').setTint(0xff00ff).setPipeline("Light2D");
this.add.image(600, 300, 'mushroom').setTintFill(0xff00ff).setPipeline("Light2D");
this.lights.enable()
this.lights.setAmbientColor("#0x999999")
this.lights.addLight(200, 300, 1000, undefined, 2)
this.lights.addLight(400, 300, 1000, undefined, 2)
this.lights.addLight(600, 300, 1000, undefined, 2)
}
}
const config = {
type: Phaser.WEBGL,
parent: 'phaser-example',
width: 800,
height: 600,
backgroundColor: '#000000',
scene: [ Example ]
};
const game = new Phaser.Game(config);