Alert icon
We're changing our privacy policy. This stuff matters.  Learn more  Dismiss

iPhone SDK Tutorial Drag Ball

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
9,435
Loading...
Alert icon
Sign in or sign up now!
Alert icon
  • likes, 5 dislikes

Link to this comment:

Share to:

Uploader Comments (brandflakeapps)

  • what are the last two lines in .m

  • - (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event {

    UITouch *myTouch = [[event allTouches] anyObject];

    ball.center = [myTouch locationInView:self.view];

    }

see all

All Comments (6)

Sign In or Sign Up now to post a comment!
  • @brandflakeapps I get an error on the last line about center not being found in UIImage...help?

  • how do u make it so the image will only drag so it wont jump if u tap on the other side of the screen

  • and how can i get this work when i want to have 2 images which can be dragable

  • thx a lot m8 !!!!!!!!!!

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more