mirror of
https://github.com/RandomityGuy/MBHaxe.git
synced 2026-04-27 13:11:42 +00:00
...
This commit is contained in:
parent
927fa6e700
commit
c14b3430d9
3 changed files with 9 additions and 1 deletions
|
|
@ -40,7 +40,7 @@ class MarbleGame {
|
||||||
static var canvas:Canvas;
|
static var canvas:Canvas;
|
||||||
static var instance:MarbleGame;
|
static var instance:MarbleGame;
|
||||||
|
|
||||||
static var currentVersion = "1.1.2";
|
static var currentVersion = "1.1.3";
|
||||||
|
|
||||||
var world:MarbleWorld;
|
var world:MarbleWorld;
|
||||||
var previewWorld:PreviewWorld;
|
var previewWorld:PreviewWorld;
|
||||||
|
|
|
||||||
|
|
@ -23,11 +23,13 @@ class Canvas extends GuiControl {
|
||||||
this.extent = new Vector(640, 480);
|
this.extent = new Vector(640, 480);
|
||||||
this.horizSizing = Width;
|
this.horizSizing = Width;
|
||||||
this.vertSizing = Height;
|
this.vertSizing = Height;
|
||||||
|
#if hl
|
||||||
Window.getInstance().addResizeEvent(() -> {
|
Window.getInstance().addResizeEvent(() -> {
|
||||||
var wnd = Window.getInstance();
|
var wnd = Window.getInstance();
|
||||||
onResize(wnd.width, wnd.height);
|
onResize(wnd.width, wnd.height);
|
||||||
Console.log('Window resized to ${wnd.width} x ${wnd.height}, scene ${scene2d.width} x ${scene2d.height}');
|
Console.log('Window resized to ${wnd.width} x ${wnd.height}, scene ${scene2d.width} x ${scene2d.height}');
|
||||||
});
|
});
|
||||||
|
#end
|
||||||
}
|
}
|
||||||
|
|
||||||
public function setContent(content:GuiControl) {
|
public function setContent(content:GuiControl) {
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,12 @@ class TouchOptionsGui extends GuiImage {
|
||||||
optionCollection.extent = new Vector(815, 500);
|
optionCollection.extent = new Vector(815, 500);
|
||||||
innerCtrl.addChild(optionCollection);
|
innerCtrl.addChild(optionCollection);
|
||||||
|
|
||||||
|
var dynamicJoystick = optionCollection.addOption(1, "Joystick Position", ["Fixed", "Dynamic"], (idx) -> {
|
||||||
|
Settings.touchSettings.dynamicJoystick = idx == 1;
|
||||||
|
return true;
|
||||||
|
}, 0.5, 118);
|
||||||
|
dynamicJoystick.setCurrentOption(Settings.touchSettings.dynamicJoystick ? 1 : 0);
|
||||||
|
|
||||||
var cameraMultiplier = optionCollection.addOption(1, "Button-Camera Factor", ["0.5", "1", "1.5", "2", "2.5", "3", "3.5"], (idx) -> {
|
var cameraMultiplier = optionCollection.addOption(1, "Button-Camera Factor", ["0.5", "1", "1.5", "2", "2.5", "3", "3.5"], (idx) -> {
|
||||||
Settings.touchSettings.buttonJoystickMultiplier = 0.5 + (idx * 0.5);
|
Settings.touchSettings.buttonJoystickMultiplier = 0.5 + (idx * 0.5);
|
||||||
return true;
|
return true;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue