Added more functionality for winning/losing/pausing