bunch of build bug fixes and some starter SC code (broke some other builds though)
small attr fetch fix