Lab 6, final

pretty much finished lab 6, although my code seems to be missing a lot
of functions etc. compared to the solutions provided.