cocos2d/cocos2d-x — pull request #608 by GMTDev (2011-12-07 04:47:44+00:00)
Title: Update CCTouch to include the ID/PID of the touch

As discussed here by Gavt: http://www.cocos2d-x.org/boards/6/topics/4043?r=5751#message-5751

"it is needed for a case like this: Say you are moving three sprites around the screen using three fingers, I receive a CCSet with three CCTouch items in it (one CCTouch for each finger). Then I take a finger off the screen so I have two left, I now receive a CCSet with two CCTouch items (two pairs of coordinates), I can't tell which finger disappeared! I could "guess" which finger disappeared by checking old coordinates but I might get it wrong if for example if all the fingers were close to each other when one was removed.

At the moment I am using the address of the "CCTouch*" to determine which finger disappeared. This works due to the code in Cocos2d's Eagleview.mm but I think this could break in a future version of Cocos2D-X. Ideally the real UITouch's ID should be passed onto the CCTouch class."