changed loop in draw and wrote psuedocode for keypress