Phaser API Documentation

  Version: 
Filter
Namespace: Phaser
Phaser
Source: src//phaser.js (Line 10)

Classes

Namespace

Members

<static, constant> AUTO: number
Focus
Focus

Description:

This setting will auto-detect if the browser is capable of suppporting WebGL. If it is, it will use the WebGL Renderer. If not, it will fall back to the Canvas Renderer.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 29)
Focus
Focus
<static, constant> CANVAS: number
Focus
Focus

Description:

Forces Phaser to only use the Canvas Renderer, regardless if the browser supports WebGL or not.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 40)
Focus
Focus
<static, constant> DOWN: number
Focus
Focus

Description:

Direction constant.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 106)
Focus
Focus
<static, constant> FOREVER: number
Focus
Focus

Description:

In Phaser the value -1 means 'forever' in lots of cases, this const allows you to use it instead to help you remember what the value is doing in your code.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 75)
Focus
Focus
<static, constant> HEADLESS: number
Focus
Focus

Description:

A Headless Renderer doesn't create either a Canvas or WebGL Renderer. However, it still absolutely relies on the DOM being present and available. This mode is meant for unit testing, not for running Phaser on the server, which is something you really shouldn't do.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 63)
Focus
Focus
<static, constant> LEFT: number
Focus
Focus

Description:

Direction constant.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 116)
Focus
Focus
<static, constant> NONE: number
Focus
Focus

Description:

Direction constant.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 86)
Focus
Focus
<static, constant> UP: number
Focus
Focus

Description:

Direction constant.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 96)
Focus
Focus
<static, constant> VERSION: string
Focus
Focus

Description:

Phaser Release Version

Type:
string
Since: 3.0.0
Source: src//const.js (Line 15)
Focus
Focus
<static, constant> WEBGL: number
Focus
Focus

Description:

Forces Phaser to use the WebGL Renderer. If the browser does not support it, there is no fallback to Canvas with this setting, so you should trap it and display a suitable message to the user.

Type:
number
Since: 3.0.0
Source: src//const.js (Line 51)
Focus
Focus

Type Definitions

DeviceConf
Focus
Focus
Properties:
name type description
os Phaser.Device.OS

The OS Device functions.

browser Phaser.Device.Browser

The Browser Device functions.

features Phaser.Device.Features

The Features Device functions.

input Phaser.Device.Input

The Input Device functions.

audio Phaser.Device.Audio

The Audio Device functions.

video Phaser.Device.Video

The Video Device functions.

fullscreen Phaser.Device.Fullscreen

The Fullscreen Device functions.

canvasFeatures Phaser.Device.CanvasFeatures

The Canvas Device functions.

Type:
object
Since: 3.0.0
Source: src/device/index.js (Line 17)
Focus
Focus