I am using Xcode to try to change my images position randomly every time a button is pushed but for some reason, the image only moves once in a while when the button is pushed even though I know it received the button's IBAction because the NSLog in the IBAction displayed in the console, I have tried it two ways and both methods only worked sporadically
Method 1:
ranX = arc4random() %320;
ranY = arc4random() %480;
myImage.center = CGPointMake(ranX, ranY);
Method 2:
myImage.center = CGPointMake(arc4random() %320, arc4random() %480);
One more thing: every time it does work, the next IBAction to run puts it right back into its original position.
More information that might be pertinent I don't know, I do not have size classes enabled, it is triggered by touch up inside. I also DID make all the RNGs arc4random_uniform. The problem is fixed, just deselect auto layout.