Graphics Gradient Fill

Apply color gradients to primitive shapes, such as circles, using the fillGradientStyle method within a Graphics object.

Graphics Gradient Fill, running
800 × 600
GitHub
class Example extends Phaser.Scene
{
    create ()
    {
        const graphics = this.add.graphics();

        graphics.fillGradientStyle(0xff0000, 0xff0000, 0x0000ff, 0x0000ff, 1);

        graphics.fillCircle(300, 300, 200);

        graphics.fillGradientStyle(0xff0000, 0xff0000, 0xffff00, 0xffff00, 1);

        graphics.fillCircle(500, 300, 140);
    }
}

const config = {
    scale: { mode: Phaser.Scale.FIT },
    width: 800,
    height: 600,
    type: Phaser.WEBGL,
    parent: 'game-container',
    scene: Example
};

const game = new Phaser.Game(config);

More in Primitives17 examples