Fixed bugs and included new feature set.