public setFormat ( Color Color, float Scale = 1.0f, |
||
Color | Color | |
Scale | float | |
Font | ||
return |
public FlxText setFormat(Color Color, float Scale = 1.0f, SpriteFont Font = null)
{
if (Font == null)
_font = FlxG.defaultFont;
else
_font = Font;
_scale = Scale;
_regen = true;
calcFrame();
return this;
}
public FlxConsole() : base() { bg = new FlxSprite(80, 40); bg.makeGraphic((uint)FlxS.GraphicsDevice.Viewport.Width - 160, (uint)FlxS.GraphicsDevice.Viewport.Height - 80, FlxColor.WHITE * 0.45f); bg.Alpha = 0.5f; add(bg); ScrollFactor.X = ScrollFactor.Y = 0; Visible = false; text = new FlxText(100, 60, FlxS.GraphicsDevice.Viewport.Width - 160, "internal console is a work in progress", FlxG.defaultFont); text.setFormat(FlxColor.WHITE); text.Alpha = 0.75f; add(text); }