Monolithic refactor

Holy shit its enormous