Hey everyone, so I am a newbie programmer and I am working on a game from the v play flappy bird template. I would like to change the button push function that makes the bird do its movement vector.
I ideally would like to have a button function in place for the player that as you hold down the button the player will vertically raise and when let go it will continuously fall. So more of a push and hold function instead of a tapping function. This is the code that controls the current movement, what would I need to do to implement this?
function push() {
wabbleX.stop()
wabbleY.stop()
audioManager.play(audioManager.idWING)
collider.body.linearVelocity = Qt.point(0,0)
var localForwardVector = collider.body.toWorldVector(Qt.point(0, upwardforce));
collider.body.applyLinearImpulse(localForwardVector, collider.body.getWorldCenter());
}