Fixed the zoom issue on high dpi
This commit is contained in:
@@ -519,7 +519,7 @@ class PlayState extends MusicBeatState
|
||||
// CHARACTER INITIALISATION
|
||||
#if REGION
|
||||
comboGroup = new FlxSpriteGroup(FlxG.width * 0.55, (FlxG.height * 0.5) - 60);
|
||||
comboGroup.maxSize = 20;
|
||||
//comboGroup.maxSize = 20;
|
||||
#end
|
||||
|
||||
// SCRIPTS & STAGE INITIALISATION
|
||||
|
||||
@@ -47,7 +47,7 @@ class Main extends Sprite
|
||||
|
||||
var gameWidth:Int = 1280; // Width of the game in pixels (might be less / more in actual pixels depending on your zoom).
|
||||
var gameHeight:Int = 720; // 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.
|
||||
var zoom:Float = 1; // If -1, zoom is automatically calculated to fit the window dimensions.
|
||||
var framerate:Int = 120; // How many frames per second the game should run at.
|
||||
var skipSplash:Bool = true; // Whether to skip the flixel splash screen that appears in release mode.
|
||||
var startFullscreen:Bool = false; // Whether to start the game in fullscreen on desktop targets
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package funkin.utils;
|
||||
|
||||
import flixel.tweens.FlxTween;
|
||||
import flixel.system.frontEnds.SoundFrontEnd;
|
||||
import flixel.system.FlxSound;
|
||||
import funkin.system.Conductor;
|
||||
@@ -189,7 +190,7 @@ class CoolUtil
|
||||
|
||||
/**
|
||||
* Plays the main menu theme.
|
||||
* @param fadeIn
|
||||
* @param fadeIn
|
||||
*/
|
||||
public static function playMenuSong(fadeIn:Bool = false) {
|
||||
if (FlxG.sound.music == null || !FlxG.sound.music.playing)
|
||||
@@ -276,7 +277,7 @@ class CoolUtil
|
||||
* ` `
|
||||
* `test2`
|
||||
* will return `["test1", "test2"]`
|
||||
* @param path
|
||||
* @param path
|
||||
* @return Array<String>
|
||||
*/
|
||||
public static function coolTextFile(path:String):Array<String>
|
||||
@@ -542,8 +543,11 @@ class CoolUtil
|
||||
spr.alpha = 1;
|
||||
spr.visible = true;
|
||||
spr.active = true;
|
||||
spr.acceleration.set();
|
||||
spr.drag.set();
|
||||
spr.antialiasing = FlxSprite.defaultAntialiasing;
|
||||
spr.rotOffset.set();
|
||||
FlxTween.cancelTweensOf(spr);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -576,7 +580,7 @@ class CoolUtil
|
||||
|
||||
/**
|
||||
* Opens an URL in the browser.
|
||||
* @param url
|
||||
* @param url
|
||||
*/
|
||||
public static function openURL(url:String) {
|
||||
#if linux
|
||||
@@ -598,8 +602,8 @@ class CoolUtil
|
||||
|
||||
/**
|
||||
* Equivalent of `Math.max`, except doesn't require a Int -> Float -> Int conversion.
|
||||
* @param p1
|
||||
* @param p2
|
||||
* @param p1
|
||||
* @param p2
|
||||
* @return return p1 < p2 ? p2 : p1
|
||||
*/
|
||||
public static inline function maxInt(p1:Int, p2:Int)
|
||||
|
||||
Reference in New Issue
Block a user