Fixed bugs, and changed parameters