Browse Source

Adjusted position a bit

rsredsq 10 years ago
parent
commit
08ae2c18b1

+ 1 - 1
PhysicsPlatformer/Resources/Modules/DPad.js

@@ -20,7 +20,7 @@ function DPad() {
       this.dpad = new Atomic.UILayout();
       this.dpad = new Atomic.UILayout();
       this.dpad.rect = this.view.rect;
       this.dpad.rect = this.view.rect;
       //sets dpad position
       //sets dpad position
-      this.dpad.setPosition(-width/4, height/10);
+      this.dpad.setPosition(-width/3, height/4);
       //move buttons a bit closer to each other
       //move buttons a bit closer to each other
       this.dpad.spacing = -30;
       this.dpad.spacing = -30;
       //if layouts are exists, add them
       //if layouts are exists, add them

+ 5 - 5
PhysicsPlatformer/Resources/Scripts/main.js

@@ -79,12 +79,12 @@ function run(daytime) {
     var jumpButtonImage = new Atomic.UIImageWidget();
     var jumpButtonImage = new Atomic.UIImageWidget();
     //load image
     //load image
     jumpButtonImage.setImage("UI/jumpButton.png");
     jumpButtonImage.setImage("UI/jumpButton.png");
-    //resize ours image by 2x
-    var jumpButtonWidth = jumpButtonImage.imageWidth*2;
-    var jumpButtonHeight = jumpButtonImage.imageHeight*2;
+    //resize ours image by 2.2x
+    var jumpButtonWidth = jumpButtonImage.imageWidth*2.2;
+    var jumpButtonHeight = jumpButtonImage.imageHeight*2.2;
     //calculate position
     //calculate position
-    var posX = Atomic.graphics.width - Atomic.graphics.width/6;
-    var posY = Atomic.graphics.height - Atomic.graphics.height/2.5;
+    var posX = Atomic.graphics.width - Atomic.graphics.width/8-jumpButtonWidth/2;
+    var posY = Atomic.graphics.height - Atomic.graphics.height/4-jumpButtonHeight/2;
 
 
     //sets jumpButton rect, specify position and end position
     //sets jumpButton rect, specify position and end position
     jumpButton.rect = [posX, posY, posX+jumpButtonWidth, posY+jumpButtonHeight];
     jumpButton.rect = [posX, posY, posX+jumpButtonWidth, posY+jumpButtonHeight];