Massive overhaul to the entire plugin