added settings and NSUserDefaults