Updated framework

Still needs some more updating, but doesn't appear broken anymore.