update engine.js to master