diff --git a/source/Main.hx b/source/Main.hx index 5d7a5573..107d01e8 100644 --- a/source/Main.hx +++ b/source/Main.hx @@ -45,13 +45,13 @@ using StringTools; class Main extends Sprite { - var gameWidth:Int; // Width of the game in pixels (might be less / more in actual pixels depending on your zoom). - var gameHeight:Int; // Height of the game in pixels (might be less / more in actual pixels depending on your zoom). - var zoom:Float = -1; // If -1, zoom is automatically calculated to fit the window dimensions. (Removed from Flixel 5.0.0) - - public static var fpsVar:FPS; + public static var fpsVar:FPS; // fps public static var game:Joalor64Game; // the main game - public static var toast:ToastCore; // credits go to MAJigsaw77 + public static var toast:ToastCore; // notification thing, credits go to MAJigsaw77 + public static var gameWidth:Int; // Width of the game in pixels (might be less / more in actual pixels depending on your zoom). + public static var gameHeight:Int; // Height of the game in pixels (might be less / more in actual pixels depending on your zoom). + + var zoom:Float = -1; // If -1, zoom is automatically calculated to fit the window dimensions. (Removed from Flixel 5.0.0) public static function main():Void { diff --git a/source/openfl/display/FPS.hx b/source/openfl/display/FPS.hx index 1c60e12c..62de403a 100644 --- a/source/openfl/display/FPS.hx +++ b/source/openfl/display/FPS.hx @@ -48,9 +48,10 @@ class FPS extends TextField currentFPS = 0; selectable = false; mouseEnabled = false; - defaultTextFormat = new TextFormat("_sans", 14, color); - autoSize = LEFT; - multiline = true; + defaultTextFormat = new TextFormat(Paths.font('vcr.ttf'), 16, color); + // set text area for the time being + width = Main.gameWidth; + height = Main.gameHeight; text = "FPS: "; cacheCount = 0;