Implemented functionality, should be working now