Crazy Carousel Game
import Felgo 4.0
import QtQuick 2.0
import "../common"
SceneBase {
id:titleScene
width: 320
height: 480
property alias backgroundImage: background
BackgroundImage {
id: background
anchors.centerIn: titleScene.gameWindowAnchorItem
source: Qt.resolvedUrl("../../assets/CarouselTitle.jpg")
}
Text {
id: text
text: "play!"
color: "black"
x: 60
y: 380
z: 1
font.pixelSize: 20
font.family: "Arial"
MouseArea {
width: parent.width
height: parent.height
onClicked: {
clickSound.play()
gameScene.startNewGame()
gameWindow.state = "game"
}
}
}
Timer {
id: colorTimer
interval: 1000
repeat: true
running: true
onTriggered: {
if(text.color == "#000000")
text.color = "yellow"
else
text.color = "black"
}
}
GameSoundEffect {
id: clickSound