added update method and made some instance variables accessible
tried to add a game loop
added update method