Fixed crash on game quit