Major refactor to support multiple floors

Hasn't seemed to break anything, fingers crossed...