title: Understanding of UIAnimation
body: <p>I am trying to use following code to perform few animations</p>
  
  <pre><code>-(void) performSlidingfromX:(int) xx fromY:(int) yy 
  {
  UIImageView *Image= [self getImage];
  
  [UIView beginAnimations:nil context:NULL];  
  [UIView setAnimationDuration: 1.0];
  [UIView setAnimationBeginsFromCurrentState:true];
  [UIView setAnimationCurve: UIViewAnimationCurveEaseOut];
  [token setFrame:CGRectMake(xx, yy, 64, 64)];
  [UIView commitAnimations];
  
  }
  </code></pre>
  
  <p>and i am calling like it in for loop </p>
  
  <pre><code>for (i = 0; i &lt; totMoves; i++) {
      Moment *m = [moments objectAtIndex:i];
      int xx= [m X];
      int yy= [m Y];
  
      [self performSlidingfromX:xx fromY:yy];
  
  }
  </code></pre>
  
  <p>The problem that i am facing is that its animating to final position, for example , If i input the following moments for  xx,yy</p>
  
  <pre><code>0,0
  50,0
  50,50
  </code></pre>
  
  <p>It moves the image from 0,0 to 50,50 diagonally, I want it to slide to horizantly first and then vertical. </p>
  
  <p>Any Help?</p>
  
  <p>Thanks</p>