Hi
I am trying to create a HUD but when I change to iPad, I see space on the right hand. https://snag.gy/fAns9J.jpg
This is my code:
import Felgo 3.0
import QtQuick 2.0
GameWindow {
id: gameWindow
screenHeight: 960
screenWidth: 640
Scene {
id: scene
width: 320
height: 480
property int score: 0
Rectangle {
anchors.fill: scene.gameWindowAnchorItem
color: "#000"
}
Rectangle {
width: scene.gameWindowAnchorItem.width
height: 50
color: "#252326"
anchors.top: scene.gameWindowAnchorItem.top
anchors.horizontalCenter: scene
}
Text {
text: "Score " + scene.score
color: "white"
anchors.horizontalCenter: scene.gameWindowAnchorItem.horizontalCenter
anchors.top: scene.gameWindowAnchorItem.top
}
Column {
anchors.centerIn: parent
spacing: 10
PlayBtn {
labelText: "Add 1"
onClicked: {
scene.increaseScore(1)
}
}
PlayBtn {
labelText: "Add 10"
onClicked: {
scene.increaseScore(10)
}
}
}
function increaseScore(amount) {
scene.score += amount
}
}
}