Updated for Xcode 6 Beta 6

It's working based on compiler suggestions, but thorough testing of code yet to be carried out