Based on spriter.js SCON Implementation. Discuss forum
bower install cc_spriter
Include cc_spriter_min.js in project.json
"jsList": [
"cc_spriter_min.js"
]
const spriter = new cc.Spriter(pathToScon);
spriter.setEntity(entityName);
spriter.setAnim(animationName);
spriter.setLoop(Boolean);
spriter.pause();
spriter.resume();
- node >= 6.0
- Bash Shell
- JAVA
- Google Closure Compiler
- compiler.jar
-
- send compiler.jar to directory
bower_components/google-closure-library/
- send compiler.jar to directory
-
- rename closure_compiler file to compiler.jar
npm i
npm run compile
├─ dist/
├──── cc_spriter_min.js
├─ bower_components/
├──── google-closure-library/
├────── compiler.jar
├──── spriterjs/
├─ demo/
├──── .cocos-project.json
├──── res
├──── index.html
├──── main.js
├──── project.json
└─ cc_spriter.js
- Canvas 2D and WebGL supports
- No global dependencies
- ~62kB size
cc_spriter is MIT licensed.