IPhone SDK: detect which touch came first on a 2 touch max application
Coding inside the function -(void) ccTouchMoved:(UITouch *)touch withEvent:(UIEvent *)event receivin开发者_如何学编程g 2 touches in the "event" variable, how can one detect which touch has lived longer? i know i could use global variables and in the touchbegin just update these variables, but I rather do it the better way, if there is any.
How about comparing the UITouch timestamp properties?
Eventually I stored pointers to the touches. saving a timestamp manually, found no other way.
精彩评论