0
votes

I need to create transparent snapshot of game (png24)

Here is an example of snapshot labs.phaser.io from Phaser3 official examples page, but it is not transparent.

1

1 Answers

1
votes

setting game background to transparent with rgba backgroundColor - works

  const config = {
    ...
    transparent: true,
    backgroundColor: 'rgba(255,110,110,0)',
    ...
  };

  const game = new Phaser.Game(config);

If you set transparent in the Game Config but didn't provide a backgroundColor then it would render as black. If you do provide a color value then it must include an alpha component.