finished motor.js