I need to associate a unique key to a UITouch instance throughout it's lifecycle -Began, Moved, Ended, Cancelled. I've been printing NSLog on a key for each touch and noticed to my suprise that each touch does not generate a unique key if the key is generated as follows:
for (UITouch *touch in touches) {
// ...
NSValue *key = [NSValue valueWithPointer:touch];
// ...
}
How can I make each touch generate a unique key?
Thanks.