separated the drawBackground method from the draw function