Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Erik Mollers updated rAF shim. Also fix the Illegal Invocation error... #1

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

miketaylr
Copy link

... for Chrome.

Was hoping this would increase perf in Opera (which doesn't have native rAF yet)... but it doesn't seem to. :/

Sooooo... anyways. Maybe this will be useful later if you can figure out why setTimeout is performing so much better than rAF.

@@ -407,7 +419,7 @@ function Survivor() {
prop: null
},

'getAnimationFrame': getAnimationFrame
'getAnimationFrame': getAnimationFrame ? getAnimationFrame.bind(window) : null
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh wait, this will explode in browsers without Function#bind. If you want, I can throw in a quick shim.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you don't mind, that'd be useful; the game does work in IE 8 as-is, FWIW.

@andreasbovens
Copy link

@scottschiller any chance this pull request can be accepted?

@scottschiller
Copy link
Owner

Ah yes, I forgot about this. I'd like it not to break IE 8. Assuming it doesn't, should be cool.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants