Fixing bugs and adding stuff