Added basic achievement functionality

Crashes a lot, though.