I am very new to using swift and Xcode in general. I wish to create a very simple game and I am trying to figure out why my ball only goes down once rather than go up and down twice when the screen is touched
override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) {
let actionUp = SKAction.moveTo(y: 1330, duration: 0.5)
let actionDown = SKAction.moveTo(y: 50, duration: 0.5)
ball?.run(actionUp)
ball?.run(actionDown)
ball?.run(actionUp)
ball?.run(actionDown)
}