cocos2d / cocos2d-html5

Cocos2d for Web Browsers. Built using JavaScript.
https://www.cocos.com
3.06k stars 905 forks source link

MouseMove causes screen freeze #3112

Open Talisca opened 9 years ago

Talisca commented 9 years ago

I've got a strange behavior in Chrome (47) in WebGL-Mode (Canvas is fine). The whole screen of the game freezes. The game itself runs smoothly (in the background..)

Steps to reproduce:

  1. Create a fresh new game
  2. Put some sprites on the screen (in my case 50 x closenormal.png)
  3. Press and hold the left mouse button
  4. Move the mouse for a while
  5. Freeze

Tested in Windows 7 Windows 8 Windows 8.1 Windows 10 Debian 8

Browsers tested: Chrome (behavior as mentioned above) Opera (works fine) Firefox (works fine) Safari (works fine)

Frameworks tested: cocos2d-html5 3.3 cocos2d-html5 3.8

TravisGesslein commented 9 years ago

Hello, I'm glad you posted this. I have experienced exactly the same issue and thought my game was at fault. But it seems the error also appears from a completely blank cocos2d-js project.

To be clear: If you schedule updates, they run smoothly in the background. The actual rendering of the scene stops while you try to click/drag the mouse around, but if you, for example, put a console.log("foo") in a scheduled frame update, it will print out correctly 30/60/whatever times per second while the screen stays frozen.

TravisGesslein commented 8 years ago

No updates?

TravisGesslein commented 8 years ago

Update: only happens when framerate is set to 30 in project.json. 60 works fine