Text#parseList()

parseList(list) → {Phaser.Text}

Converts the given array into a tab delimited string and then updates this Text object.
This is mostly used when you want to display external data using tab stops.

The array can be either single or multi dimensional depending on the result you need:

[ 'a', 'b', 'c' ] would convert in to "a\tb\tc".

Where as:

[ [ 'a', 'b', 'c' ], [ 'd', 'e', 'f'] ]

would convert in to: "a\tb\tc\nd\te\tf"

Parameters
Name Type Description
list array

The array of data to convert into a string.

Returns

This Text instance.

Source code: gameobjects/Text.js (Line 1286)
doc_phaser
2017-02-14 11:14:14
Comments
Leave a Comment

Please login to continue.