implemented better saver and loader, tested, works well