UIDynamicItemBehavior *custom=[[UIDynamicItemBehavior alloc]initWithItems:self.squareViews]; custom.elasticity=1;//0~1,数值越大弹性越大 [self.animator addBehavior:custom];