icon update
|
|
@ -2,7 +2,7 @@
|
||||||
<!-- Replace com.example.heapsandroid.helloword with the identifier of your game below, e.g.
|
<!-- Replace com.example.heapsandroid.helloword with the identifier of your game below, e.g.
|
||||||
com.gamemaker.game -->
|
com.gamemaker.game -->
|
||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
package="com.example.heapsandroid.helloworld"
|
package="com.randomityguy.mbhaxe.mbp"
|
||||||
android:installLocation="auto"
|
android:installLocation="auto"
|
||||||
android:versionCode="1"
|
android:versionCode="1"
|
||||||
android:versionName="1.0">
|
android:versionName="1.0">
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
<background android:drawable="@drawable/ic_launcher_background"/>
|
<background android:drawable="@mipmap/ic_launcher_background"/>
|
||||||
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
|
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
|
||||||
|
<monochrome android:drawable="@mipmap/ic_launcher_monochrome"/>
|
||||||
</adaptive-icon>
|
</adaptive-icon>
|
||||||
|
Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 7.6 KiB |
|
After Width: | Height: | Size: 2.4 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 4.1 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 5.3 KiB |
|
After Width: | Height: | Size: 5.3 KiB |
|
Before Width: | Height: | Size: 4.6 KiB After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 3.5 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 6.8 KiB After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 8.3 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
Before Width: | Height: | Size: 9.7 KiB After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 58 KiB |
|
After Width: | Height: | Size: 58 KiB |
10
src/Main.hx
|
|
@ -30,13 +30,13 @@ class Main extends hxd.App {
|
||||||
hl.UI.closeConsole();
|
hl.UI.closeConsole();
|
||||||
#end
|
#end
|
||||||
#if js
|
#if js
|
||||||
var zoomRatio = Util.isTouchDevice() ? js.Browser.window.screen.height * js.Browser.window.devicePixelRatio / 600 : js.Browser.window.devicePixelRatio; // js.Browser.window.devicePixelRatio;
|
var zoomRatio = Util.isTouchDevice() ? js.Browser.window.screen.height * js.Browser.window.devicePixelRatio / 768 : js.Browser.window.devicePixelRatio; // js.Browser.window.devicePixelRatio;
|
||||||
s2d.scaleMode = Zoom(zoomRatio);
|
|
||||||
#end
|
|
||||||
#if android
|
|
||||||
var zoomRatio = Window.getInstance().height / 600;
|
|
||||||
s2d.scaleMode = Zoom(zoomRatio);
|
s2d.scaleMode = Zoom(zoomRatio);
|
||||||
#end
|
#end
|
||||||
|
// #if android
|
||||||
|
// var zoomRatio = Window.getInstance().height / 768;
|
||||||
|
// s2d.scaleMode = Zoom(zoomRatio);
|
||||||
|
// #end
|
||||||
|
|
||||||
#if android
|
#if android
|
||||||
Window.getInstance().addEventTarget(ev -> {
|
Window.getInstance().addEventTarget(ev -> {
|
||||||
|
|
|
||||||
|
|
@ -371,6 +371,7 @@ class Settings {
|
||||||
#if hl
|
#if hl
|
||||||
Window.getInstance().resize(optionsSettings.screenWidth, optionsSettings.screenHeight);
|
Window.getInstance().resize(optionsSettings.screenWidth, optionsSettings.screenHeight);
|
||||||
Window.getInstance().displayMode = optionsSettings.isFullScreen ? FullscreenResize : Windowed;
|
Window.getInstance().displayMode = optionsSettings.isFullScreen ? FullscreenResize : Windowed;
|
||||||
|
uiScale = 1 / Window.getInstance().windowToPixelRatio;
|
||||||
#end
|
#end
|
||||||
#if js
|
#if js
|
||||||
Window.getInstance().propagateKeyEvents = true;
|
Window.getInstance().propagateKeyEvents = true;
|
||||||
|
|
@ -380,13 +381,13 @@ class Settings {
|
||||||
var wnd = Window.getInstance();
|
var wnd = Window.getInstance();
|
||||||
var zoomRatio = 1.0;
|
var zoomRatio = 1.0;
|
||||||
#if js
|
#if js
|
||||||
var zoomRatio = Util.isTouchDevice() ? js.Browser.window.screen.height * js.Browser.window.devicePixelRatio / 600 : js.Browser.window.devicePixelRatio; // 768 / js.Browser.window.innerHeight; // js.Browser.window.innerHeight * js.Browser.window.devicePixelRatio / 768;
|
var zoomRatio = Util.isTouchDevice() ? js.Browser.window.screen.height * js.Browser.window.devicePixelRatio / 768 : js.Browser.window.devicePixelRatio; // 768 / js.Browser.window.innerHeight; // js.Browser.window.innerHeight * js.Browser.window.devicePixelRatio / 768;
|
||||||
Settings.zoomRatio = zoomRatio;
|
|
||||||
#end
|
|
||||||
#if android
|
|
||||||
var zoomRatio = Window.getInstance().height / 600;
|
|
||||||
Settings.zoomRatio = zoomRatio;
|
Settings.zoomRatio = zoomRatio;
|
||||||
#end
|
#end
|
||||||
|
// #if android
|
||||||
|
// var zoomRatio = Window.getInstance().height / 768;
|
||||||
|
// Settings.zoomRatio = zoomRatio;
|
||||||
|
// #end
|
||||||
#if hl
|
#if hl
|
||||||
Settings.optionsSettings.screenWidth = cast wnd.width;
|
Settings.optionsSettings.screenWidth = cast wnd.width;
|
||||||
Settings.optionsSettings.screenHeight = cast wnd.height;
|
Settings.optionsSettings.screenHeight = cast wnd.height;
|
||||||
|
|
|
||||||