0

I have 10 images in viewcontroller and i want to shuffle images at run time without repetition and want to apply touch event on those and find the tag of image which is touched

  • would it be safe to assume you have an nsmutablearray of 10 images or image views and you want to know how to randomly re-order the array? – Augie Aug 29 '12 at 18:18

1 Answers1

1

I'd guess best bet would be put images in an Mutable Array and shuffle like this. Shuffling an array in objective-c

And add touch events in one of the ways mentioned here IOS: event when an Imageview is touched

and trigger the view in your app to re-shuffle and re-draw the images on applicationDidBecomeActive or something like that.

Community
  • 1
  • 1
Augie
  • 1,341
  • 1
  • 11
  • 18