updated cleanUp function on game