Closer to being functional

Still some things to work out (probably).