You can use Bitmap Fonts with the FlxBitmapText
object. You have to create and pass a FlxBitmapFont
, which you can create in a number of different ways, such as AngelCode.
// creates a new FlxBitmapText, using a monospace 8x8px font.
text = new FlxBitmapText(FlxBitmapFont.fromMonospace("assets/tiny-font.png",
FlxBitmapFont.DEFAULT_CHARS, FlxPoint.get(8, 8)));
// set the text's text to "Hello, World!"
text.text = "Hello, World!";