Add exit function for gameplay