Restructured everything to make it a plugin