Strange TouchDispatcher behavior in 2.0 version

Strange TouchDispatcher behavior in 2.0 version
0.0 0


In my game scene has multiple objects. All they swallow touch and registered with a priority > 0.
After a few touches, some of them no longer respond to the touch, and most bizarre menu button(CCMenuItemSprite) does not respond.
It happens by accident somehow. And in the release and debug.
It may manifest itself after the second contact, may, after the tenth and may not manifest itself until the next run.
A bit similar to that which is an uninitialized variable, but in my code, I just registered TouchDelegate and swallow touches.
Sorry for my English is not my native language.


Could you make a simple demo based on HelloWorld to reproduce this issue? :slight_smile:


I will soon send a test project will dedicate. I think it shows when I use CCDirector::sharedDirector()->getTouchDispatcher()->setPriority();


I see this bug if I run the project 3 or 4 times in a row.


Thank you, I will test the project you uploaded and try to fix this issue. :slight_smile:


Thank you, your team is doing a great job


Hi, Issue #1308 created for this bug.


Hi, Serg Merg,
This issue has been fixed, you should download the codes from github (, just have a try. :slight_smile:


Thanks, works fine.