more raintime refactoring