Move function creation outside of loops when creating components with sprite()
Suppress remaning jshint warnings
Merge pull request #586 from starwed/hint

Fix or suppress warnings produced by jshint