These archived docs are for Phaser 2.2.2 Phaser 3 docs can be found on
Phaser CE docs can be found on the Phaser CE Documentation site.


Phaser. LoaderParser

new LoaderParser()

Phaser.LoaderParser parses data objects from Phaser.Loader that need more preparation before they can be inserted into the Cache.

Source code: loader/LoaderParser.js, line 12

Public Methods

<static> bitmapFont(game, xml, cacheKey, xSpacing, ySpacing)

Parse a Bitmap Font from an XML file.

Name Type Argument Default Description
game Phaser.Game

A reference to the current game.

xml object

XML data you want to parse.

cacheKey string

The key of the texture this font uses in the cache.

xSpacing number <optional>

Additional horizontal spacing between the characters.

ySpacing number <optional>

Additional vertical spacing between the characters.

Source code: loader/LoaderParser.js, line 14