added plugin capability
switched extends.js with inherits.js