implemented rudimentary save system