Added 2 import packages for screenshot and code to take screenshot when
frame == 1