Phaser API Documentation

  Version: 

Member of: Phaser.Core

<static> CreateRenderer(game)

Description:

Called automatically by Phaser.Game and responsible for creating the renderer it will use.

Relies upon two webpack global flags to be defined: WEBGL_RENDERER and CANVAS_RENDERER during build time, but not at run-time.

Parameters:

name type description
game Phaser.Game

The Phaser.Game instance on which the renderer will be set.

Since: 3.0.0