Exit game cleanly when winning

Change-Id: Ie1a50721f90982c0d7b3273f091013bea13962c4