drying up rollNumbers function

added totalFrames variable