0

I've recently begun learning Swift and attempting to wrap my head around IOS app development. I'm on day 2 of actually creating apps and have been putting together a simple game of rock paper scissors just to test my knowledge so far.

The problem is that I would like to be able to have the user drag their selection (of either rock, paper, or scissors) to the "play area" rather than just tapping on a choice.
Can anyone explain how this can be achieved in somewhat simple terms?

tux3
  • 7,171
  • 6
  • 39
  • 51
npburns224
  • 632
  • 7
  • 11

1 Answers1

0

Im not able to add comments due to the reason that my points is not enough, but here some answered question that can give an insight to you. UIView drag (image and text).

I think the killer point is, UIView is subclass of UIResponder class. This means UIView can handle events, including touch event. You need to implement (maybe override) some methods, such as touchesMoved:withEvent:

Community
  • 1
  • 1
Salihcyilmaz
  • 326
  • 1
  • 3
  • 11