updated gameplay in driver and added a thread for gameplay