Pulling things out of render methods to ensure smooth framerate