Renamed the files to it looked nicer and also started some of the portal
manipulation code, could probably be used in the api too.