updated image cycle script