Fixed a lot of errors by updating the libraries and created new class.