Depreciated code replacement; misc changes